devstaff-crete/DevStaff-Heraklion

View on GitHub

Showing 1,636 of 1,636 total issues

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

        toArray( dom.slides.querySelectorAll( 'iframe[src*="youtube.com/embed/"]' ) ).forEach( function( el ) {
            var src = el.getAttribute( 'src' );
            if( !/enablejsapi\=1/gi.test( src ) ) {
                el.setAttribute( 'src', src + ( !/\?/.test( src ) ? '?' : '&' ) + 'enablejsapi=1' );
            }
Severity: Major
Found in meetups/meetup06-MobileDev/x-platform/js/reveal.js and 1 other location - About 3 hrs to fix
meetups/meetup06-MobileDev/x-platform/js/reveal.js on lines 2709..2714

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 100.

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

        toArray( dom.slides.querySelectorAll( 'iframe[src*="player.vimeo.com/"]' ) ).forEach( function( el ) {
            var src = el.getAttribute( 'src' );
            if( !/api\=1/gi.test( src ) ) {
                el.setAttribute( 'src', src + ( !/\?/.test( src ) ? '?' : '&' ) + 'api=1' );
            }
Severity: Major
Found in meetups/meetup06-MobileDev/x-platform/js/reveal.js and 1 other location - About 3 hrs to fix
meetups/meetup06-MobileDev/x-platform/js/reveal.js on lines 2701..2706

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 100.

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 render has 81 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    function render(forceRerender) {
      if (render.destroyed) return;
      var i;
      var ii;
      var item;
Severity: Major
Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js - About 3 hrs to fix

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

        if (!self.options.scrollingY) {
    
          top = self.__scrollTop;
    
        } else {
    Severity: Major
    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 3 hrs to fix
    meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 5995..6007

    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 97.

    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

        if (!self.options.scrollingX) {
    
          left = self.__scrollLeft;
    
        } else {
    Severity: Major
    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 3 hrs to fix
    meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 6009..6021

    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 97.

    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 compile has 77 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        compile: function($element, $attr) {
          var listEl = jqLite('<div class="list">')
            .append($element.contents())
            .addClass($attr.type);
    
    
    Severity: Major
    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js - About 3 hrs to fix

      Function slide has 77 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          function slide( h, v, f, o ) {
      
              // Remember where we were at before
              previousSlide = currentSlide;
      
      
      Severity: Major
      Found in meetups/meetup06-MobileDev/x-platform/js/reveal.js - About 3 hrs to fix

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

              return {
                pre: function($scope, $element, $attrs, navBarCtrl) {
                  // only register the plain HTML, the navBarCtrl takes care of scope/compile/link
        
                  var parentViewCtrl = $element.parent().data('$ionViewController');
        meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js on lines 11383..11399

        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 96.

        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

              return {
                pre: function($scope, $element, $attrs, navBarCtrl) {
                  // only register the plain HTML, the navBarCtrl takes care of scope/compile/link
        
                  var parentViewCtrl = $element.parent().data('$ionViewController');
        meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js on lines 11281..11297

        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 96.

        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 actionSheet has 75 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

          function actionSheet(opts) {
            var scope = $rootScope.$new(true);
        
            extend(scope, {
              cancel: noop,
        Severity: Major
        Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js - About 3 hrs to fix

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

            resize: function(continueScrolling) {
              var self = this;
              if (!self.__container || !self.options) return;
          
              // Update Scroller dimensions for changed content
          Severity: Major
          Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 3 hrs to fix
          meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 6934..6947

          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 95.

          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

              resize: function(continueScrolling) {
                var self = this;
                if (!self.__container || !self.options) return;
          
                // Update Scroller dimensions for changed content
          Severity: Major
          Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 3 hrs to fix
          meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 5614..5627

          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 95.

          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 Param has 74 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

            this.Param = function Param(id, type, config, location) {
              var self = this;
              config = unwrapShorthand(config);
              type = getType(config, type, location);
              var arrayMode = getArrayMode();

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

                        else {
                            if( fragments.prev ) dom.controlsLeft.forEach( function( el ) { el.classList.add( 'fragmented', 'enabled' ); } );
                            if( fragments.next ) dom.controlsRight.forEach( function( el ) { el.classList.add( 'fragmented', 'enabled' ); } );
                        }
            Severity: Major
            Found in meetups/meetup06-MobileDev/x-platform/js/reveal.js and 1 other location - About 2 hrs to fix
            meetups/meetup06-MobileDev/x-platform/js/reveal.js on lines 2388..2391

            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 93.

            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

                        if( isVerticalSlide( currentSlide ) ) {
                            if( fragments.prev ) dom.controlsUp.forEach( function( el ) { el.classList.add( 'fragmented', 'enabled' ); } );
                            if( fragments.next ) dom.controlsDown.forEach( function( el ) { el.classList.add( 'fragmented', 'enabled' ); } );
                        }
            Severity: Major
            Found in meetups/meetup06-MobileDev/x-platform/js/reveal.js and 1 other location - About 2 hrs to fix
            meetups/meetup06-MobileDev/x-platform/js/reveal.js on lines 2392..2395

            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 93.

            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 Hilitor has 72 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            function Hilitor(id, tag)
            {
            
              var targetNode = document.getElementById(id) || document.body;
              var hiliteTag = tag || "EM";
            Severity: Major
            Found in meetups/meetup06-MobileDev/x-platform/plugin/search/search.js - About 2 hrs to fix

              Function link has 71 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                    return function link($scope, $element, $attr, ctrls) {
                      var childScope;
                      var childElement;
                      var tabsCtrl = ctrls[0];
                      var tabCtrl = ctrls[1];
              Severity: Major
              Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js - About 2 hrs to fix

                Function controller has 70 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    controller: ['$scope', '$element', '$attrs', function($scope, $element, $attrs) {
                      var _this = this;
                
                      var continuous = $scope.$eval($scope.doesContinue) === true;
                      var shouldAutoPlay = isDefined($attrs.autoPlay) ? !!$scope.autoPlay : false;
                Severity: Major
                Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js - About 2 hrs to fix

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

                            function widthGetter(scope, locals) {
                              var result = parsedValue(scope, locals);
                              if (result.charAt && result.charAt(result.length - 1) === '%') {
                                return Math.floor(parseInt(result) / 100 * scrollView.__clientWidth);
                              }
                  meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js on lines 8759..8765

                  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 91.

                  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

                            function heightGetter(scope, locals) {
                              var result = parsedValue(scope, locals);
                              if (result.charAt && result.charAt(result.length - 1) === '%') {
                                return Math.floor(parseInt(result) / 100 * scrollView.__clientHeight);
                              }
                  meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js on lines 8766..8772

                  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 91.

                  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

                  Severity
                  Category
                  Status
                  Source
                  Language