myems-admin/js/plugins/fullcalendar/fullcalendar.js

Summary

Maintainability
F
1 mo
Test Coverage

File fullcalendar.js has 5375 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/*!
 * FullCalendar v2.1.1
 * Docs & License: http://arshaw.com/fullcalendar/
 * (c) 2013 Adam Shaw
 */
Severity: Major
Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 2 wks to fix

    Function EventManager has 510 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function EventManager(options) { // assumed to be a calendar
        var t = this;
        
        
        // exports
    Severity: Major
    Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 2 days to fix

      Function Calendar has 449 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function Calendar(element, instanceOptions) {
          var t = this;
      
      
      
      
      Severity: Major
      Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 2 days to fix

        Function View has 263 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function View(calendar) {
            var t = this;
            
            // exports
            t.calendar = calendar;
        Severity: Major
        Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 day to fix

          Function Header has 168 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          function Header(calendar, options) {
              var t = this;
              
              // exports
              t.render = render;
          Severity: Major
          Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 6 hrs to fix

            Function renderSection has 115 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                function renderSection(position) {
                    var sectionEl = $('<div class="fc-' + position + '"/>');
                    var buttonStr = options.header[position];
            
                    if (buttonStr) {
            Severity: Major
            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 4 hrs to fix

              Function _fetchEventSource has 91 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  function _fetchEventSource(source, callback) {
                      var i;
                      var fetchers = fc.sourceFetchers;
                      var res;
              
              
              Severity: Major
              Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 3 hrs to fix

                Function buildEvent has 75 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    function buildEvent(data, source) { // source may be undefined!
                        var out = {};
                        var start;
                        var end;
                        var allDay;
                Severity: Major
                Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 3 hrs to fix

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

                      limitRow: function(row, levelLimit) {
                          var _this = this;
                          var view = this.view;
                          var rowStruct = this.rowStructs[row];
                          var moreNodes = []; // array of "more" <a> links and <td> DOM nodes
                  Severity: Major
                  Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 2 hrs to fix

                    Function renderEventRow has 69 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        renderEventRow: function(row, rowSegs) {
                            var view = this.view;
                            var colCnt = view.colCnt;
                            var segLevels = this.buildSegLevels(rowSegs); // group into sub-arrays of levels
                            var levelCnt = Math.max(1, segLevels.length); // ensure at least one level
                    Severity: Major
                    Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 2 hrs to fix

                      Function mutateEvent has 58 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          function mutateEvent(event, newStart, newEnd) {
                              var oldAllDay = event._allDay;
                              var oldStart = event._start;
                              var oldEnd = event._end;
                              var clearEnd = false;
                      Severity: Major
                      Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 2 hrs to fix

                        Function segDragMousedown has 58 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            segDragMousedown: function(seg, ev) {
                                var _this = this;
                                var view = this.view;
                                var el = seg.el;
                                var event = seg.event;
                        Severity: Major
                        Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 2 hrs to fix

                          Function makeMoment has 56 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                          function makeMoment(args, parseAsUTC, parseZone) {
                              var input = args[0];
                              var isSingleString = args.length == 1 && typeof input === 'string';
                              var isAmbigTime;
                              var isAmbigZone;
                          Severity: Major
                          Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 2 hrs to fix

                            Function renderSegHtml has 54 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                renderSegHtml: function(seg, disableResizing) {
                                    var view = this.view;
                                    var event = seg.event;
                                    var isDraggable = view.isEventDraggable(event);
                                    var isResizable = !disableResizing && seg.isEnd && view.isEventResizable(event);
                            Severity: Major
                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 2 hrs to fix

                              Function mutateEvents has 54 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  function mutateEvents(events, clearEnd, forceAllDay, dateDelta, durationDelta) {
                                      var isAmbigTimezone = t.getIsAmbigTimezone();
                                      var undoFunctions = [];
                              
                                      $.each(events, function(i, event) {
                              Severity: Major
                              Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 2 hrs to fix

                                Function segResizeMousedown has 48 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                    segResizeMousedown: function(seg, ev) {
                                        var _this = this;
                                        var view = this.view;
                                        var el = seg.el;
                                        var event = seg.event;
                                Severity: Minor
                                Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                  Function position has 43 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      position: function() {
                                          var options = this.options;
                                          var origin = this.el.offsetParent().offset();
                                          var width = this.el.outerWidth();
                                          var height = this.el.outerHeight();
                                  Severity: Minor
                                  Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                    Function renderView has 39 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                        function renderView(delta, viewName) {
                                            ignoreWindowResize++;
                                    
                                            // if viewName is changing, destroy the old view
                                            if (currentView && viewName && currentView.name !== viewName) {
                                    Severity: Minor
                                    Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                      Function dayMousedown has 39 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                          dayMousedown: function(ev) {
                                              var _this = this;
                                              var view = this.view;
                                              var isSelectable = view.opt('selectable');
                                              var dates = null; // the inclusive dates of the selection. will be null if no selection
                                      Severity: Minor
                                      Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                        Function renderSegHtml has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                            renderSegHtml: function(seg, disableResizing) {
                                                var view = this.view;
                                                var isRTL = view.opt('isRTL');
                                                var event = seg.event;
                                                var isDraggable = view.isEventDraggable(event);
                                        Severity: Minor
                                        Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                          Function highlightSkeletonHtml has 36 lines of code (exceeds 25 allowed). Consider refactoring.
                                          Open

                                              highlightSkeletonHtml: function(start, end) {
                                                  var view = this.view;
                                                  var segs = this.rangeToSegs(start, end);
                                                  var cellHtml = '';
                                                  var col = 0;
                                          Severity: Minor
                                          Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                            Function formatRangeWithChunks has 36 lines of code (exceeds 25 allowed). Consider refactoring.
                                            Open

                                            function formatRangeWithChunks(date1, date2, chunks, separator, isRTL) {
                                                var chunkStr; // the rendering of the chunk
                                                var leftI;
                                                var leftStr = '';
                                                var rightI;
                                            Severity: Minor
                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                              Function getEventSkinCss has 34 lines of code (exceeds 25 allowed). Consider refactoring.
                                              Open

                                                  getEventSkinCss: function(event) {
                                                      var view = this.view;
                                                      var source = event.source || {};
                                                      var eventColor = event.color;
                                                      var sourceColor = source.color;
                                              Severity: Minor
                                              Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                Function distributeHeight has 33 lines of code (exceeds 25 allowed). Consider refactoring.
                                                Open

                                                function distributeHeight(els, availableHeight, shouldRedistribute) {
                                                
                                                    // *FLOORING NOTE*: we floor in certain places because zoom can give inaccurate floating-point dimensions,
                                                    // and it is better to be shorter than taller, to avoid creating unnecessary scrollbars.
                                                
                                                
                                                Severity: Minor
                                                Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                  Function setHeight has 32 lines of code (exceeds 25 allowed). Consider refactoring.
                                                  Open

                                                      setHeight: function(totalHeight, isAuto) {
                                                          var eventLimit;
                                                          var scrollerHeight;
                                                  
                                                          if (this.bottomRuleHeight === null) {
                                                  Severity: Minor
                                                  Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                    Function showSegPopover has 32 lines of code (exceeds 25 allowed). Consider refactoring.
                                                    Open

                                                        showSegPopover: function(date, cell, moreLink, segs) {
                                                            var _this = this;
                                                            var view = this.view;
                                                            var moreWrap = moreLink.parent(); // the <div> wrapper around the <a>
                                                            var topEl; // the element we want to match the top coordinate of
                                                    Severity: Minor
                                                    Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                      Function buildEventSource has 32 lines of code (exceeds 25 allowed). Consider refactoring.
                                                      Open

                                                          function buildEventSource(sourceInput) { // will return undefined if invalid source
                                                              var normalizers = fc.sourceNormalizers;
                                                              var source;
                                                              var i;
                                                      
                                                      
                                                      Severity: Minor
                                                      Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

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

                                                            bindSegHandlers: function() {
                                                                var _this = this;
                                                                var view = this.view;
                                                        
                                                                $.each(
                                                        Severity: Minor
                                                        Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                          Function renderMoreLink has 30 lines of code (exceeds 25 allowed). Consider refactoring.
                                                          Open

                                                              renderMoreLink: function(cell, hiddenSegs) {
                                                                  var _this = this;
                                                                  var view = this.view;
                                                          
                                                                  return $('<a class="fc-more"/>')
                                                          Severity: Minor
                                                          Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                            Function slatRowHtml has 30 lines of code (exceeds 25 allowed). Consider refactoring.
                                                            Open

                                                                slatRowHtml: function() {
                                                                    var view = this.view;
                                                                    var calendar = view.calendar;
                                                                    var isRTL = view.opt('isRTL');
                                                                    var html = '';
                                                            Severity: Minor
                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                              Function rangeToSegments has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                                                              Open

                                                                  function rangeToSegments(start, end) {
                                                              
                                                                      var rowCnt = t.rowCnt;
                                                                      var colCnt = t.colCnt;
                                                                      var segments = []; // array of segments to return
                                                              Severity: Minor
                                                              Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                                Function getHtmlRenderer has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                                                                Open

                                                                    getHtmlRenderer: function(rendererName, rowType) {
                                                                        var view = this.view;
                                                                        var generalName; // like "cellHtml"
                                                                        var specificName; // like "dayCellHtml". based on rowType
                                                                        var provider; // either the View or the RowRenderer subclass, whichever provided the method
                                                                Severity: Minor
                                                                Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                                  Function renderEventTable has 29 lines of code (exceeds 25 allowed). Consider refactoring.
                                                                  Open

                                                                      renderEventTable: function(events) {
                                                                          var tableEl = $('<table><tr/></table>');
                                                                          var trEl = tableEl.find('tr');
                                                                          var segs = this.eventsToSegs(events);
                                                                          var segCols;
                                                                  Severity: Minor
                                                                  Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                                    Function stop has 27 lines of code (exceeds 25 allowed). Consider refactoring.
                                                                    Open

                                                                        stop: function(shouldRevert, callback) {
                                                                            var _this = this;
                                                                            var revertDuration = this.options.revertDuration;
                                                                    
                                                                            function complete() {
                                                                    Severity: Minor
                                                                    Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

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

                                                                      function intersectionToSeg(subjectStart, subjectEnd, intervalStart, intervalEnd) {
                                                                          var segStart, segEnd;
                                                                          var isStart, isEnd;
                                                                      
                                                                          if (subjectEnd > intervalStart && subjectStart < intervalEnd) { // in bounds at all?
                                                                      Severity: Minor
                                                                      Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

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

                                                                            getCell: function(x, y) {
                                                                                var cell = null;
                                                                                var rows = this.rows;
                                                                                var cols = this.cols;
                                                                                var r = -1;
                                                                        Severity: Minor
                                                                        Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

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

                                                                              startListening: function(ev) {
                                                                                  var scrollParent;
                                                                                  var cell;
                                                                          
                                                                                  if (!this.isListening) {
                                                                          Severity: Minor
                                                                          Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

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

                                                                                renderSegPopoverContent: function(date, segs) {
                                                                                    var view = this.view;
                                                                                    var isTheme = view.opt('theme');
                                                                                    var title = date.format(view.opt('dayPopoverFormat'));
                                                                                    var content = $(
                                                                            Severity: Minor
                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

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

                                                                                  buildCoords: function(rows, cols) {
                                                                                      var colCnt = this.view.colCnt;
                                                                                      var originTop = this.el.offset().top;
                                                                                      var snapTime = moment.duration(+this.minTime);
                                                                                      var p = null;
                                                                              Severity: Minor
                                                                              Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

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

                                                                                    generateSegPositionCss: function(seg) {
                                                                                        var view = this.view;
                                                                                        var isRTL = view.opt('isRTL');
                                                                                        var shouldOverlap = view.opt('slotEventOverlap');
                                                                                        var backwardCoord = seg.backwardCoord; // the left side if LTR. the right side if RTL. floating-point
                                                                                Severity: Minor
                                                                                Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 1 hr to fix

                                                                                  Avoid deeply nested control flow statements.
                                                                                  Open

                                                                                                                          if (
                                                                                                                              button.hasClass(tm + '-state-active') ||
                                                                                                                              button.hasClass(tm + '-state-disabled')
                                                                                                                          ) {
                                                                                                                              button.removeClass(tm + '-state-hover');
                                                                                  Severity: Major
                                                                                  Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 45 mins to fix

                                                                                    Function formatRangeWithChunks has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                    Open

                                                                                    function formatRangeWithChunks(date1, date2, chunks, separator, isRTL) {
                                                                                    Severity: Minor
                                                                                    Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 35 mins to fix

                                                                                      Function formatRange has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                      Open

                                                                                      function formatRange(date1, date2, formatStr, separator, isRTL) {
                                                                                      Severity: Minor
                                                                                      Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 35 mins to fix

                                                                                        Function mutateEvents has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                                                                        Open

                                                                                            function mutateEvents(events, clearEnd, forceAllDay, dateDelta, durationDelta) {
                                                                                        Severity: Minor
                                                                                        Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 35 mins to fix

                                                                                          Avoid too many return statements within this function.
                                                                                          Open

                                                                                              return '';
                                                                                          Severity: Major
                                                                                          Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js - About 30 mins to fix

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

                                                                                                    for (var row=0; row<rowCnt; row++) {
                                                                                            
                                                                                                        // first and last cell offset for the row
                                                                                                        var rowCellOffsetFirst = row * colCnt;
                                                                                                        var rowCellOffsetLast = rowCellOffsetFirst + colCnt - 1;
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 day to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 5044..5079

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

                                                                                            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 computeSlotSegCoords(seg, seriesBackwardPressure, seriesBackwardCoord) {
                                                                                                var forwardSegs = seg.forwardSegs;
                                                                                                var i;
                                                                                            
                                                                                                if (seg.forwardCoord === undefined) { // not already computed
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 day to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4450..4483

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

                                                                                            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() {
                                                                                            
                                                                                                    if (opt('weekends') === false) {
                                                                                                        hiddenDays.push(0, 6); // 0=sunday, 6=saturday
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 6 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4867..4889

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

                                                                                            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

                                                                                            function computeForwardSlotSegs(levels) {
                                                                                                var i, level;
                                                                                                var j, seg;
                                                                                                var k;
                                                                                            
                                                                                            
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 6 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4394..4411

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

                                                                                            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

                                                                                            function computeSlotSegPressures(seg) {
                                                                                                var forwardSegs = seg.forwardSegs;
                                                                                                var forwardPressure = 0;
                                                                                                var i, forwardSeg;
                                                                                            
                                                                                            
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 5 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4416..4439

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

                                                                                            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

                                                                                                            $.ajax($.extend({}, ajaxDefaults, source, {
                                                                                                                data: data,
                                                                                                                success: function(events) {
                                                                                                                    events = events || [];
                                                                                                                    var res = applyAll(success, this, arguments);
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 5 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 1048..1066

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

                                                                                            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

                                                                                                groupSegCols: function(segs) {
                                                                                                    var view = this.view;
                                                                                                    var segCols = [];
                                                                                                    var i;
                                                                                            
                                                                                            
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 4 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 5323..5337

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

                                                                                            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

                                                                                                groupSegRows: function(segs) {
                                                                                                    var view = this.view;
                                                                                                    var segRows = [];
                                                                                                    var i;
                                                                                            
                                                                                            
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 4 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6407..6421

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

                                                                                            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 (this.scrollLeftVel < 0) { // scrolling left?
                                                                                                        if (el.scrollLeft() <= 0) { // already scrolled all the left?
                                                                                                            this.scrollLeftVel = 0;
                                                                                                        }
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 4 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 3643..3652

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

                                                                                            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 (this.scrollTopVel < 0) { // scrolling up?
                                                                                                        if (el.scrollTop() <= 0) { // already scrolled all the way up?
                                                                                                            this.scrollTopVel = 0;
                                                                                                        }
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 4 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 3654..3663

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

                                                                                            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

                                                                                            function applyAll(functions, thisObj, args) {
                                                                                                if ($.isFunction(functions)) {
                                                                                                    functions = [ functions ];
                                                                                                }
                                                                                                if (functions) {
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 3 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 1928..1940

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

                                                                                            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

                                                                                                function fetchEvents(start, end) {
                                                                                                    rangeStart = start;
                                                                                                    rangeEnd = end;
                                                                                                    cache = [];
                                                                                                    var fetchID = ++currentFetchID;
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 2 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 943..953

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

                                                                                            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

                                                                                                this.year(a[0]) // TODO: find a way to do this in one shot
                                                                                                    .month(a[1])
                                                                                                    .date(a[2])
                                                                                                    .hours(a[3])
                                                                                                    .minutes(a[4])
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 2 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 2640..2646

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

                                                                                            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

                                                                                                    this.year(a[0]) // TODO: find a way to do this in one shot
                                                                                                        .month(a[1])
                                                                                                        .date(a[2])
                                                                                                        .hours(a[3])
                                                                                                        .minutes(a[4])
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 2 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 2588..2594

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

                                                                                            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

                                                                                            function computeSlotSegCollisions(seg, otherSegs, results) {
                                                                                                results = results || [];
                                                                                            
                                                                                                for (var i=0; i<otherSegs.length; i++) {
                                                                                                    if (isSlotSegCollision(seg, otherSegs[i])) {
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 2 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4506..4516

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

                                                                                            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

                                                                                                function removeEventSource(source) {
                                                                                                    sources = $.grep(sources, function(src) {
                                                                                                        return !isSourcesEqual(src, source);
                                                                                                    });
                                                                                                    // remove all client events from that source
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 2 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 1103..1112

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

                                                                                            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

                                                                                                    return '' +
                                                                                                        '<table>' +
                                                                                                            '<thead>' +
                                                                                                                '<tr>' +
                                                                                                                    '<td class="' + this.widgetHeaderClass + '">' +
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 2 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 8007..8023

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

                                                                                            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

                                                                                                    return '' +
                                                                                                        '<table>' +
                                                                                                            '<thead>' +
                                                                                                                '<tr>' +
                                                                                                                    '<td class="' + this.widgetHeaderClass + '">' +
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 2 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 7480..7492

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

                                                                                            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 ((level0 = levels[0])) {
                                                                                            
                                                                                                    for (i = 0; i < level0.length; i++) {
                                                                                                        computeSlotSegPressures(level0[i]);
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 2 hrs to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4353..4362

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

                                                                                            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

                                                                                                    return '<a class="' + classes.join(' ') + '"' +
                                                                                                        (event.url ?
                                                                                                            ' href="' + htmlEscape(event.url) + '"' :
                                                                                                            ''
                                                                                                            ) +
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 5173..5187

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

                                                                                            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

                                                                                                    return '<a class="' + classes.join(' ') + '"' +
                                                                                                            (event.url ?
                                                                                                                ' href="' + htmlEscape(event.url) + '"' :
                                                                                                                ''
                                                                                                                ) +
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6322..6341

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

                                                                                            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

                                                                                                incrementDate: function(date, delta) {
                                                                                                    var out = date.clone().stripTime().add(delta, 'days');
                                                                                                    out = this.skipHiddenDays(out, delta < 0 ? -1 : 1);
                                                                                                    return out;
                                                                                                },
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 7858..7862

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

                                                                                            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

                                                                                                incrementDate: function(date, delta) {
                                                                                                    var out = date.clone().stripTime().add(delta, 'days');
                                                                                                    out = this.skipHiddenDays(out, delta < 0 ? -1 : 1);
                                                                                                    return out;
                                                                                                },
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 8370..8374

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

                                                                                            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

                                                                                                        for (i = 0; i < cols.length; i++) {
                                                                                                            if (x >= cols[i][0] && x < cols[i][1]) {
                                                                                                                c = i;
                                                                                                                break;
                                                                                                            }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 3212..3217

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

                                                                                            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

                                                                                                        for (i = 0; i < rows.length; i++) {
                                                                                                            if (y >= rows[i][0] && y < rows[i][1]) {
                                                                                                                r = i;
                                                                                                                break;
                                                                                                            }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 3219..3224

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

                                                                                            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 trigger(name, thisObj) {
                                                                                                    return calendar.trigger.apply(
                                                                                                        calendar,
                                                                                                        [name, thisObj || t].concat(Array.prototype.slice.call(arguments, 2), [t])
                                                                                                    );
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4598..4603

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

                                                                                            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

                                                                                                function cellToDate() {
                                                                                                    var cellOffset = cellToCellOffset.apply(null, arguments);
                                                                                                    var dayOffset = cellOffsetToDayOffset(cellOffset);
                                                                                                    var date = dayOffsetToDate(dayOffset);
                                                                                                    return date;
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4929..4934

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

                                                                                            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

                                                                                                    this.title = this.calendar.formatRange(
                                                                                                        this.start,
                                                                                                        this.end.clone().subtract(1), // make inclusive by subtracting 1 ms
                                                                                                        this.opt('titleFormat'),
                                                                                                        ' \u2014 ' // emphasized dash
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 8340..8345

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

                                                                                            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

                                                                                                    this.title = this.calendar.formatRange(
                                                                                                        this.start,
                                                                                                        this.end.clone().subtract(1), // make inclusive by subtracting 1 ms
                                                                                                        this.opt('titleFormat'),
                                                                                                        ' \u2014 ' // emphasized dash
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 7829..7834

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

                                                                                            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

                                                                                                trigger: function(name) {
                                                                                                    if (this.options[name]) {
                                                                                                        this.options[name].apply(this, Array.prototype.slice.call(arguments, 1));
                                                                                                    }
                                                                                                }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 3548..3552

                                                                                            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

                                                                                                    for (i=0; i<sources.length; i++) {
                                                                                                        if ($.isArray(sources[i].events)) {
                                                                                                            sources[i].events = $.grep(sources[i].events, filter, true);
                                                                                                        }
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 1188..1192

                                                                                            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

                                                                                                trigger: function(name) {
                                                                                                    if (this.options[name]) {
                                                                                                        this.options[name].apply(this, Array.prototype.slice.call(arguments, 1));
                                                                                                    }
                                                                                                },
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 3149..3153

                                                                                            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

                                                                                            function compareForwardSlotSegs(seg1, seg2) {
                                                                                                // put higher-pressure first
                                                                                                return seg2.forwardPressure - seg1.forwardPressure ||
                                                                                                    // put segments that are closer to initial edge first (and favor ones with no coords yet)
                                                                                                    (seg1.backwardCoord || 0) - (seg2.backwardCoord || 0) ||
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4526..4533

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

                                                                                            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 (!event.source) {
                                                                                                            if (stick) {
                                                                                                                stickySource.events.push(event);
                                                                                                                event.source = stickySource;
                                                                                                            }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 1159..1165

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

                                                                                            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

                                                                                            function firstDefined() {
                                                                                                for (var i=0; i<arguments.length; i++) {
                                                                                                    if (arguments[i] !== undefined) {
                                                                                                        return arguments[i];
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 1943..1949

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

                                                                                            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 isEventResizable(event) {
                                                                                                    var source = event.source || {};
                                                                                            
                                                                                                    return firstDefined(
                                                                                                        event.durationEditable,
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6999..7010

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

                                                                                            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 isEventDraggable(event) {
                                                                                                    var source = event.source || {};
                                                                                            
                                                                                                    return firstDefined(
                                                                                                        event.startEditable,
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 7013..7024

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

                                                                                            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

                                                                                                                            .mousedown(function() {
                                                                                                                                // the *down* effect (mouse pressed in).
                                                                                                                                // only on buttons that are not the "active" tab, or disabled
                                                                                                                                button
                                                                                                                                    .not('.' + tm + '-state-active')
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 1199..1206

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

                                                                                            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() {
                                                                                                                                    // the *hover* effect.
                                                                                                                                    // only on buttons that are not the "active" tab, or disabled
                                                                                                                                    button
                                                                                                                                        .not('.' + tm + '-state-active')
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 1186..1193

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

                                                                                            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 ($.isFunction(source.data)) {
                                                                                                                // supplied as a function that returns a key/value object
                                                                                                                customData = source.data();
                                                                                                            }
                                                                                                            else {
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 1 hr to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 1025..1032

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

                                                                                            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 generateShortTimeFormat(options, langData) {
                                                                                                return langData.longDateFormat('LT')
                                                                                                    .replace(':mm', '(:mm)')
                                                                                                    .replace(/(\Wmm)$/, '($1)') // like above, but for foreign langs
                                                                                                    .replace(/\s*a$/i, 't'); // convert to AM/PM/am/pm to lowercase one-letter. remove any spaces beforehand
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 55 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 7904..7909

                                                                                            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

                                                                                            function generateAgendaAxisFormat(options, langData) {
                                                                                                return langData.longDateFormat('LT')
                                                                                                    .replace(':mm', '(:mm)')
                                                                                                    .replace(/(\Wmm)$/, '($1)') // like above, but for foreign langs
                                                                                                    .replace(/\s*a$/i, 'a'); // convert AM/PM/am/pm to lowercase. remove any spaces beforehand
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 55 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 123..128

                                                                                            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

                                                                                                function getAndRenderEvents() {
                                                                                                    if (!options.lazyFetching || isFetchNeeded(currentView.start, currentView.end)) {
                                                                                                        fetchAndRenderEvents();
                                                                                                    }
                                                                                                    else {
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 55 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 511..518

                                                                                            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

                                                                                                    for (i = 0; i < events.length; i++) {
                                                                                                        if (events[i].allDay) {
                                                                                                            dayEvents.push(events[i]);
                                                                                                        }
                                                                                                        else {
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 55 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 3718..3724

                                                                                            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

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

                                                                                                function dateToCell(date) {
                                                                                                    var dayOffset = dateToDayOffset(date);
                                                                                                    var cellOffset = dayOffsetToCellOffset(dayOffset);
                                                                                                    var cell = cellOffsetToCell(cellOffset);
                                                                                                    return cell;
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 50 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4980..4985

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

                                                                                            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

                                                                                                function trigger(name, thisObj) {
                                                                                                    if (options[name]) {
                                                                                                        return options[name].apply(
                                                                                                            thisObj || _element,
                                                                                                            Array.prototype.slice.call(arguments, 2)
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 50 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 685..692

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

                                                                                            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

                                                                                                for (; i>=0; i--) {
                                                                                                    res = obj[parts[i].toLowerCase()];
                                                                                                    if (res !== undefined) {
                                                                                                        return res;
                                                                                                    }
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 50 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 1831..1836

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

                                                                                            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

                                                                                                destroyDrag: function() {
                                                                                                    this.timeGrid.destroyDrag();
                                                                                                    if (this.dayGrid) {
                                                                                                        this.dayGrid.destroyDrag();
                                                                                                    }
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 50 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 8299..8304

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

                                                                                            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

                                                                                                destroySelection: function() {
                                                                                                    this.timeGrid.destroySelection();
                                                                                                    if (this.dayGrid) {
                                                                                                        this.dayGrid.destroySelection();
                                                                                                    }
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 50 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 8275..8280

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

                                                                                            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

                                                                                                    for (j=0; j<levels.length; j++) {
                                                                                                        if (!computeSlotSegCollisions(seg, levels[j]).length) {
                                                                                                            break;
                                                                                                        }
                                                                                                    }
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 45 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4379..4383

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

                                                                                            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 render(inc) {
                                                                                                    if (!content) {
                                                                                                        initialRender();
                                                                                                    }
                                                                                                    else if (elementVisible()) {
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 45 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 248..257

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

                                                                                            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 5 locations. Consider refactoring.
                                                                                            Open

                                                                                                destroyEl: function() {
                                                                                                    if (this.el) {
                                                                                                        this.el.remove();
                                                                                                        this.el = null;
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 4 other locations - About 40 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 5003..5008
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 5037..5042
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6068..6073
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6111..6116

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

                                                                                            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 5 locations. Consider refactoring.
                                                                                            Open

                                                                                                destroyHighlight: function() {
                                                                                                    if (this.highlightEl) {
                                                                                                        this.highlightEl.remove();
                                                                                                        this.highlightEl = null;
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 4 other locations - About 40 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 3854..3859
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 5003..5008
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 5037..5042
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6068..6073

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

                                                                                            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 5 locations. Consider refactoring.
                                                                                            Open

                                                                                                destroyHighlight: function() {
                                                                                                    if (this.highlightEls) {
                                                                                                        this.highlightEls.remove();
                                                                                                        this.highlightEls = null;
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 4 other locations - About 40 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 3854..3859
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 5003..5008
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6068..6073
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6111..6116

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

                                                                                            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 5 locations. Consider refactoring.
                                                                                            Open

                                                                                                destroyHelper: function() {
                                                                                                    if (this.helperEls) {
                                                                                                        this.helperEls.remove();
                                                                                                        this.helperEls = null;
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 4 other locations - About 40 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 3854..3859
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 5037..5042
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6068..6073
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6111..6116

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

                                                                                            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 5 locations. Consider refactoring.
                                                                                            Open

                                                                                                destroyHelper: function() {
                                                                                                    if (this.helperEl) {
                                                                                                        this.helperEl.remove();
                                                                                                        this.helperEl = null;
                                                                                                    }
                                                                                            Severity: Major
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 4 other locations - About 40 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 3854..3859
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 5003..5008
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 5037..5042
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6111..6116

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

                                                                                            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

                                                                                                showEvent: function(event) {
                                                                                                    this.segEach(function(seg) {
                                                                                                        seg.el.css('visibility', '');
                                                                                                    }, event);
                                                                                                },
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 35 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6810..6814

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

                                                                                            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

                                                                                                    out._id = data._id || (data.id === undefined ? '_fc' + eventGUID++ : data.id + '');
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 35 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 1239..1239

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

                                                                                            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

                                                                                                hideEvent: function(event) {
                                                                                                    this.segEach(function(seg) {
                                                                                                        seg.el.css('visibility', 'hidden');
                                                                                                    }, event);
                                                                                                },
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 35 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 6802..6806

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

                                                                                            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 3 locations. Consider refactoring.
                                                                                            Open

                                                                                                incrementDate: function(date, delta) {
                                                                                                    return date.clone().stripTime().add(delta, 'months').startOf('month');
                                                                                                },
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 2 other locations - About 35 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 7816..7818
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 8327..8329

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

                                                                                            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 3 locations. Consider refactoring.
                                                                                            Open

                                                                                                incrementDate: function(date, delta) {
                                                                                                    return date.clone().stripTime().add(delta, 'weeks').startOf('week');
                                                                                                },
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 2 other locations - About 35 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 7737..7739
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 7816..7818

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

                                                                                            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 3 locations. Consider refactoring.
                                                                                            Open

                                                                                                incrementDate: function(date, delta) {
                                                                                                    return date.clone().stripTime().add(delta, 'weeks').startOf('week');
                                                                                                },
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 2 other locations - About 35 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 7737..7739
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 8327..8329

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

                                                                                            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 3 locations. Consider refactoring.
                                                                                            Open

                                                                                                defaultButtonText: {
                                                                                                    prev: "prev",
                                                                                                    next: "next",
                                                                                                    prevYear: "prev year",
                                                                                                    nextYear: "next year",
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 2 other locations - About 35 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 68..77
                                                                                            myems-admin/js/plugins/nouslider/angular-nouislider.js on lines 5..14

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

                                                                                            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

                                                                                                weekNumberStyleAttr: function() {
                                                                                                    if (this.weekNumberWidth !== null) {
                                                                                                        return 'style="width:' + this.weekNumberWidth + 'px"';
                                                                                                    }
                                                                                                    return '';
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 30 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 8094..8099

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

                                                                                            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

                                                                                                axisStyleAttr: function() {
                                                                                                    if (this.axisWidth !== null) {
                                                                                                         return 'style="width:' + this.axisWidth + 'px"';
                                                                                                    }
                                                                                                    return '';
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 30 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.js on lines 7569..7574

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

                                                                                            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 isSlotSegCollision(seg1, seg2) {
                                                                                                return seg1.bottom > seg2.top && seg1.top < seg2.bottom;
                                                                                            }
                                                                                            Severity: Minor
                                                                                            Found in myems-admin/js/plugins/fullcalendar/fullcalendar.js and 1 other location - About 30 mins to fix
                                                                                            myems-admin/js/plugins/fullcalendar/fullcalendar.min.js on lines 4520..4522

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

                                                                                            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

                                                                                            There are no issues that match your filters.

                                                                                            Category
                                                                                            Status