mambax7/extcal

View on GitHub

Showing 1,163 of 1,163 total issues

Function setPosition has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
Open

        setPosition: function (pos, offset, vis, dur, easing) {
            var exp = this.exp,
                stl = exp.wrapper.style,
                offset = offset || 0,
                pos = pos || {
Severity: Minor
Found in assets/js/highslide-full.js - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function focusTopmost has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
Open

        focusTopmost: function () {
            var topZ = 0,
                topmostKey = -1,
                expanders = hs.expanders,
                exp,
Severity: Minor
Found in assets/js/highslide-full.js - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function focusTopmost has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
Open

        focusTopmost: function () {
            var topZ = 0,
                topmostKey = -1,
                expanders = hs.expanders,
                exp,
Severity: Minor
Found in assets/js/highslide.js - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function transit has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
Open

        transit: function (adj, exp) {
            var last = exp || hs.getExpander();
            exp = last;
            if (hs.upcoming) return false;
            else hs.last = last;
Severity: Minor
Found in assets/js/highslide-with-gallery.js - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function setPosition has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
Open

        setPosition: function (pos, offset, vis, dur, easing) {
            var exp = this.exp,
                stl = exp.wrapper.style,
                offset = offset || 0,
                pos = pos || {
Severity: Minor
Found in assets/js/highslide-with-gallery.js - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function calcExpanded has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
Open

        calcExpanded: function () {
            var exp = this.exp;
            this.justify = 'auto';


Severity: Minor
Found in assets/js/highslide.js - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function focusTopmost has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
Open

        focusTopmost: function () {
            var topZ = 0,
                topmostKey = -1,
                expanders = hs.expanders,
                exp,
Severity: Minor
Found in assets/js/highslide-with-gallery.js - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function setPosition has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
Open

        setPosition: function (pos, offset, vis, dur, easing) {
            var exp = this.exp,
                stl = exp.wrapper.style,
                offset = offset || 0,
                pos = pos || {
Severity: Minor
Found in assets/js/highslide.js - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function setSelection has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
Open

    public function setSelection($events)
    {
        $daysInMonth = $this->cE->getDaysInMonth($this->year, $this->month);
        for ($i = 1; $i <= $daysInMonth; ++$i) {
            $stamp1 = $this->cE->dateToStamp($this->year, $this->month, $i);
Severity: Minor
Found in class/pear/Calendar/docs/examples/20.php - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function rrmdir has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
Open

    public static function rrmdir($src)
    {
        // Only continue if user is a 'global' Admin
        if (!($GLOBALS['xoopsUser'] instanceof \XoopsUser) || !$GLOBALS['xoopsUser']->isAdmin()) {
            return false;
Severity: Minor
Found in class/Common/FilesManagement.php - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Method modifierCouleur has 10 arguments (exceeds 4 allowed). Consider refactoring.
Open

        $colorHexa,
        $incrementRouge,
        $incrementVert,
        $incrementBleu,
        $plancherRouge = 0,
Severity: Major
Found in class/ColorTools.php - About 1 hr to fix

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

                if (up) {
                    this.wrapper.style.visibility = 'visible';
                    this.content.style.visibility = 'visible';
                    this.a.className += ' highslide-active-anchor';
                }
    Severity: Major
    Found in assets/js/highslide.js and 1 other location - About 1 hr to fix
    assets/js/highslide-with-gallery.js on lines 1614..1618

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 60.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

                if (up) {
                    this.wrapper.style.visibility = 'visible';
                    this.content.style.visibility = 'visible';
                    this.a.className += ' highslide-active-anchor';
                }
    Severity: Major
    Found in assets/js/highslide-with-gallery.js and 1 other location - About 1 hr to fix
    assets/js/highslide.js on lines 1366..1370

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 60.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

                if (this.transitions[1] == 'crossfade' && hs.upcoming) {
                    hs.getExpander(hs.upcoming).cancelLoading();
                    hs.upcoming = null;
                }
    Severity: Major
    Found in assets/js/highslide-full.js and 1 other location - About 1 hr to fix
    assets/js/highslide-with-gallery.js on lines 2079..2082

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 60.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

                    hs.viewport = hs.createElement('div', {
                            className: 'highslide-viewport highslide-viewport-size'
                        }, {
                            visibility: (hs.safari && hs.uaVersion < 525) ? 'visible' : 'hidden'
                        }, hs.container, 1
    Severity: Major
    Found in assets/js/highslide-full.js and 1 other location - About 1 hr to fix
    assets/js/highslide-with-gallery.js on lines 775..780

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 60.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

                    hs.viewport = hs.createElement('div', {
                            className: 'highslide-viewport highslide-viewport-size'
                        }, {
                            visibility: (hs.safari && hs.uaVersion < 525) ? 'visible' : 'hidden'
                        }, hs.container, 1
    Severity: Major
    Found in assets/js/highslide-with-gallery.js and 1 other location - About 1 hr to fix
    assets/js/highslide-full.js on lines 951..956

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 60.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

                if (this.transitions[1] == 'crossfade' && hs.upcoming) {
                    hs.getExpander(hs.upcoming).cancelLoading();
                    hs.upcoming = null;
                }
    Severity: Major
    Found in assets/js/highslide-with-gallery.js and 1 other location - About 1 hr to fix
    assets/js/highslide-full.js on lines 2589..2592

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 60.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Function sizeOverlayBox has 31 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

            sizeOverlayBox: function (doWrapper, doPanels) {
                var overlayBox = this.overlayBox,
                    x = this.x,
                    y = this.y;
                hs.setStyles(overlayBox, {
    Severity: Minor
    Found in assets/js/highslide-full.js - About 1 hr to fix

      Function close has 31 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

              close: function () {
                  if (this.isClosing || !this.isExpanded) return;
                  if (this.transitions[1] == 'crossfade' && hs.upcoming) {
                      hs.getExpander(hs.upcoming).cancelLoading();
                      hs.upcoming = null;
      Severity: Minor
      Found in assets/js/highslide-full.js - About 1 hr to fix

        Function Outline has 31 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            hs.Outline = function (outlineType, onLoad) {
                this.onLoad = onLoad;
                this.outlineType = outlineType;
                var v = hs.uaVersion, tr;
        
        
        Severity: Minor
        Found in assets/js/highslide-full.js - About 1 hr to fix
          Severity
          Category
          Status
          Source
          Language