devstaff-crete/DevStaff-Heraklion

View on GitHub

Showing 1,642 of 1,642 total issues

Function promise has 26 lines of code (exceeds 25 allowed). Consider refactoring.
Open

            var promise = $http(httpConfig).then(function(response) {
              var data = response.data,
                promise = value.$promise;

              if (data) {

    Function goBack has 26 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        goBack: function(backCount) {
          if (isDefined(backCount) && backCount !== -1) {
            if (backCount > -1) return;
    
            var currentHistory = viewHistory.histories[this.currentHistoryId()];
    Severity: Minor
    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js - About 1 hr to fix

      Function collectEventData has 26 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          collectEventData: function collectEventData(element, eventType, touches, ev) {
      
            // find out pointerType
            var pointerType = ionic.Gestures.POINTER_TOUCH;
            if(ev.type.match(/mouse/) || ionic.Gestures.PointerEvent.matchType(ionic.Gestures.POINTER_MOUSE, ev)) {
      Severity: Minor
      Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js - About 1 hr to fix

        Function getRenderer has 26 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

          function getRenderer(attrs, scope) {
            var statics = function() {
              return {
                enter: function (element, target, cb) { target.after(element); cb(); },
                leave: function (element, cb) { element.remove(); cb(); }

          Function touchMove has 26 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              self.touchMove = function(e) {
                if (self.options.freeze || !self.__isDown ||
                  (!self.__isDown && e.defaultPrevented) ||
                  (e.target.tagName === 'TEXTAREA' && e.target.parentElement.querySelector(':focus')) ) {
                  return;
          Severity: Minor
          Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js - About 1 hr to fix

            Consider simplifying this complex logical expression.
            Open

                      if (nativeScrolling) {
                        // use native scrolling
                        $element.addClass('overflow-scroll');
            
                        scrollViewOptions = {
            Severity: Major
            Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js - About 1 hr to fix

              Consider simplifying this complex logical expression.
              Open

                    } else if (currentView && currentView.historyId !== historyId &&
                              hist.cursor > -1 && hist.stack.length > 0 && hist.cursor < hist.stack.length &&
                              hist.stack[hist.cursor].stateId === currentStateId) {
                      // they just changed to a different history and the history already has views in it
                      var switchToView = hist.stack[hist.cursor];
              Severity: Major
              Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic-angular.js - About 1 hr to fix

                Consider simplifying this complex logical expression.
                Open

                        if( activeElementIsCE || activeElementIsInput || (event.shiftKey && event.keyCode !== 32) || event.altKey || event.ctrlKey || event.metaKey ) return;
                Severity: Major
                Found in meetups/meetup06-MobileDev/x-platform/js/reveal.js - About 1 hr to fix

                  Consider simplifying this complex logical expression.
                  Open

                              if( autoSlide && !autoSlidePaused && !isPaused() && !isOverview() && ( !Reveal.isLastSlide() || availableFragments().next || config.loop === true ) ) {
                                  autoSlideTimeout = setTimeout( navigateNext, autoSlide );
                                  autoSlideStartTime = Date.now();
                              }
                  Severity: Major
                  Found in meetups/meetup06-MobileDev/x-platform/js/reveal.js - About 1 hr to fix

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

                          getContentHeight: function() {
                            return Math.max(self.__content.scrollHeight, self.__content.offsetHeight + (self.__content.offsetTop * 2));
                          }
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 55 mins to fix
                    meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 6894..6896

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

                    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 (keyboardHasPlugin()) {
                          window.removeEventListener('native.keyboardshow', debouncedKeyboardNativeShow );
                          window.removeEventListener('native.keyboardhide', keyboardFocusOut);
                        } else {
                          document.body.removeEventListener('focusout', keyboardFocusOut);
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 55 mins to fix
                    meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 3704..3709

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

                    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 (!self.__didWaitForSize && !self.__maxScrollLeft && !self.__maxScrollTop) {
                          self.__didWaitForSize = true;
                          self.__waitForSize();
                        }
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 55 mins to fix
                    meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 7151..7154

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

                    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

                            getContentHeight: function() {
                              return Math.max(self.__content.scrollHeight, self.__content.offsetHeight + (self.__content.offsetTop * 2));
                            }
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 55 mins to fix
                    meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 4765..4767

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

                    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 (!self.__didWaitForSize && !self.__maxScrollLeft && !self.__maxScrollTop) {
                            self.__didWaitForSize = true;
                            self.__waitForSize();
                          }
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 55 mins to fix
                    meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 6596..6599

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

                    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 (keyboardHasPlugin()) {
                        window.addEventListener('native.keyboardshow', debouncedKeyboardNativeShow);
                        window.addEventListener('native.keyboardhide', keyboardFocusOut);
                      } else {
                        document.body.addEventListener('focusout', keyboardFocusOut);
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 55 mins to fix
                    meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 3660..3665

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

                    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 RevealNotes has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                    Open

                    var RevealNotes = (function() {
                    
                        function openNotes() {
                            var jsFileLocation = document.querySelector('script[src$="notes.js"]').src;  // this js file path
                            jsFileLocation = jsFileLocation.replace(/notes\.js(\?.*)?$/, '');   // the js folder path
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/plugin/notes/notes.js - About 55 mins 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

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

                              if (self.isFullScreen) {
                                document.body.classList.add('fullscreen');
                              } else {
                                document.body.classList.remove('fullscreen');
                              }
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js and 1 other location - About 55 mins to fix
                    meetups/meetup06-MobileDev/x-platform/js/reveal.js on lines 798..803

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

                    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

                            anchors.forEach( function( element ) {
                                if( /^(http|www)/gi.test( element.getAttribute( 'href' ) ) ) {
                                    element.addEventListener( 'click', onPreviewLinkClicked, false );
                                }
                            } );
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/js/reveal.js and 1 other location - About 55 mins to fix
                    meetups/meetup06-MobileDev/x-platform/js/reveal.js on lines 1329..1333

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

                    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

                            anchors.forEach( function( element ) {
                                if( /^(http|www)/gi.test( element.getAttribute( 'href' ) ) ) {
                                    element.removeEventListener( 'click', onPreviewLinkClicked, false );
                                }
                            } );
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/js/reveal.js and 1 other location - About 55 mins to fix
                    meetups/meetup06-MobileDev/x-platform/js/reveal.js on lines 1314..1318

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

                    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( config.rtl ) {
                                dom.wrapper.classList.add( 'rtl' );
                            }
                            else {
                                dom.wrapper.classList.remove( 'rtl' );
                    Severity: Minor
                    Found in meetups/meetup06-MobileDev/x-platform/js/reveal.js and 1 other location - About 55 mins to fix
                    meetups/meetup06-MobileDev/x-platform/ionic/js/ionic.js on lines 2394..2398

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

                    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