codefordayton/metroparks-tribute

View on GitHub

Showing 5,402 of 5,402 total issues

File insivia-frmp-script.js has 3013 lines of code (exceeds 250 allowed). Consider refactoring.
Open

var $ = jQuery.noConflict();
(function($, root, undefined) {
  $(function() {
    'use strict';

Severity: Major
Found in tribute_files/insivia-frmp-script.js - About 1 wk to fix

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

                for(var i = 0; i<= json.facilities.length; ++i) {
                  if(json.facilities[i]) {
                    
                    results += '<li id="' + slugify(json.facilities[i].name) + '-shelter-list-item" class="insivia-frmp-list-item">'+
                               '<span class="insivia-frmp-list-item-content insivia-frmp-row">'+                            
    Severity: Major
    Found in tribute_files/insivia-frmp-script.js and 1 other location - About 4 days to fix
    tribute_files/insivia-frmp-script.js on lines 1505..1555

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

    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(var i = 0; i<= json.facilities.length; ++i) {
                  if(json.facilities[i]) {
                    
                    results += '<li id="' + slugify(json.facilities[i].name) + '-shelter-list-item" class="insivia-frmp-list-item-item">'+
                               '<span class="insivia-frmp-list-item-content insivia-frmp-row">'+                            
    Severity: Major
    Found in tribute_files/insivia-frmp-script.js and 1 other location - About 4 days to fix
    tribute_files/insivia-frmp-script.js on lines 1369..1419

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

    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

    File main.js has 906 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    /**jQuery.browser.mobile (http://detectmobilebrowser.com/)**/
    (function(a){(jQuery.browser=jQuery.browser||{}).mobile=/(android|bb\d+|meego).+mobile|avantgo|android|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od|ad)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(a)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(a.substr(0,4))})(navigator.userAgent||navigator.vendor||window.opera);
    
    var isXs = (jQuery(window).width() <= 480);
    var isSm = (jQuery(window).width() < 480);
    Severity: Major
    Found in tribute_files/main.js - About 2 days to fix

      Function registration_calendar has 426 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          function registration_calendar(today, facilityID, camping) {
            
            //camping = 1||0
            (camping) ? camping : camping = 0;
            
      Severity: Major
      Found in tribute_files/insivia-frmp-script.js - About 2 days to fix

        Function put_to_slide has 419 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            function put_to_slide(api, target, type, id, tag, maxNum) {
              if (!api || !target) return;
              
              //Types: home, upcoming, event, location, tag, facility
              
        Severity: Major
        Found in tribute_files/insivia-frmp-script.js - About 2 days to fix

          Function api_call has 376 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              function api_call(url, typeOfCall, m, y) {
                var results = '',
                    calendarEvents = '',
                    calendarListEvents = '',
                    pageCount;
          Severity: Major
          Found in tribute_files/insivia-frmp-script.js - About 1 day to fix

            Function form_results has 357 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                function form_results(query) {
                  var url,
                      type,
                      results = '',
                      resultsFor = $('results-for'),
            Severity: Major
            Found in tribute_files/insivia-frmp-script.js - About 1 day to fix

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

                          $.each($('.departure_date'), function() {
                              var departure_date = $(this).val(),
                                  targetID = $(this).closest('form').attr('id'),
                                  textArea = $('#'+targetID).find('textarea')[1],
                                  jsnString = $(textArea).text(),
              Severity: Major
              Found in tribute_files/insivia-frmp-script.js and 1 other location - About 1 day to fix
              tribute_files/insivia-frmp-script.js on lines 3566..3583

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

              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

                          $.each($('.departure_time'), function() {
                              var departure_time = $(this).val(),
                                  targetID = $(this).closest('form').attr('id'),
                                  textArea = $('#'+targetID).find('textarea')[1],
                                  jsnString = $(textArea).text(),
              Severity: Major
              Found in tribute_files/insivia-frmp-script.js and 1 other location - About 1 day to fix
              tribute_files/insivia-frmp-script.js on lines 3584..3601

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

              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

                                  $.each($('.nav-links span.current'), function(i, val) {
                                    var classes = $(this).attr('class'),
                                        href,
                                        dta = $(this).attr('data-page');  
                                                      
              Severity: Major
              Found in tribute_files/insivia-frmp-script.js and 1 other location - About 1 day to fix
              tribute_files/insivia-frmp-script.js on lines 3992..4007

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

              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

                                  $.each($('.nav-links span.current'), function(i, val) {
                                    var classes = $(this).attr('class'),
                                        href,
                                        dta = $(this).attr('data-page');  
                                                      
              Severity: Major
              Found in tribute_files/insivia-frmp-script.js and 1 other location - About 1 day to fix
              tribute_files/insivia-frmp-script.js on lines 4036..4051

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

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

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

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

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

              Refactorings

              Further Reading

              Function generate_pop_up has 348 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  function generate_pop_up(api, id, type) {
                    var popUp = '',
                        url = baseUrl,
                        previous = document.referrer;
                    if(!api||!id) return;
              Severity: Major
              Found in tribute_files/insivia-frmp-script.js - About 1 day to fix

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

                                if (options.horizontal == 'right') {
                                    $wrapper.css('left', linkOffset.left + $tooltipanchor.outerWidth() + options.offsetleft);
                                } else if (options.horizontal == 'leftedge') {
                                    $wrapper.css('left', linkOffset.left + $tooltipanchor.outerWidth() - $tooltipanchor.outerWidth() +  options.offsetleft);
                                } else if (options.horizontal == 'left') {
                Severity: Major
                Found in tribute_files/popup.js and 1 other location - About 1 day to fix
                tribute_files/popup.js on lines 614..624

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

                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 (options.vertical == 'bottom') {
                                    $wrapper.css('top', linkOffset.top + $tooltipanchor.outerHeight() + options.offsettop);
                                } else if (options.vertical == 'bottomedge') {
                                    $wrapper.css('top', linkOffset.top + $tooltipanchor.outerHeight() - $el.outerHeight() + options.offsettop);
                                } else if (options.vertical == 'top') {
                Severity: Major
                Found in tribute_files/popup.js and 1 other location - About 1 day to fix
                tribute_files/popup.js on lines 601..611

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

                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

                    } else if (typeOfBox == "Activity") {
                        activityInfoBoxes.each(function(){
                        box = jQuery(this);
                        boxData = jQuery(this).attr("data-info-box");
                
                
                Severity: Major
                Found in tribute_files/main.js and 1 other location - About 1 day to fix
                tribute_files/main.js on lines 253..301

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

                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(typeOfBox == "Amenity") {
                
                        amenityInfoBoxes.each(function(){
                        box = jQuery(this);
                        boxData = jQuery(this).attr("data-info-box");
                Severity: Major
                Found in tribute_files/main.js and 1 other location - About 1 day to fix
                tribute_files/main.js on lines 278..301

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

                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

                      calendarBuild += '<div class="insivia-frmp-calendar-days-of-the-week insivia-frmp-row">' +
                                        '<div class="insivia-frmp-calendar-' + dotwArray[0].toLowerCase() + ' insivia-frmp-calendar-day-of-the-week insivia-col-7">' + dotwArray[0] + '</div>' +
                                        '<div class="insivia-frmp-calendar-' + dotwArray[1].toLowerCase() + ' insivia-frmp-calendar-day-of-the-week insivia-col-7">' + dotwArray[1] + '</div>' +
                                        '<div class="insivia-frmp-calendar-' + dotwArray[2].toLowerCase() + ' insivia-frmp-calendar-day-of-the-week insivia-col-7">' + dotwArray[2] + '</div>' +
                                        '<div class="insivia-frmp-calendar-' + dotwArray[3].toLowerCase() + ' insivia-frmp-calendar-day-of-the-week insivia-col-7">' + dotwArray[3] + '</div>' +
                Severity: Major
                Found in tribute_files/insivia-frmp-script.js and 1 other location - About 1 day to fix
                tribute_files/insivia-frmp-script.js on lines 935..943

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

                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

                      calendarBuild += '<div class="insivia-frmp-calendar-days-of-the-week insivia-frmp-row">' +
                                        '<div class="insivia-frmp-calendar-' + dotwArray[0].toLowerCase() + ' insivia-frmp-calendar-day-of-the-week insivia-col-7">' + dotwArray[0] + '</div>' +
                                        '<div class="insivia-frmp-calendar-' + dotwArray[1].toLowerCase() + ' insivia-frmp-calendar-day-of-the-week insivia-col-7">' + dotwArray[1] + '</div>' +
                                        '<div class="insivia-frmp-calendar-' + dotwArray[2].toLowerCase() + ' insivia-frmp-calendar-day-of-the-week insivia-col-7">' + dotwArray[2] + '</div>' +
                                        '<div class="insivia-frmp-calendar-' + dotwArray[3].toLowerCase() + ' insivia-frmp-calendar-day-of-the-week insivia-col-7">' + dotwArray[3] + '</div>' +
                Severity: Major
                Found in tribute_files/insivia-frmp-script.js and 1 other location - About 1 day to fix
                tribute_files/insivia-frmp-script.js on lines 3193..3201

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

                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

                                  } else if( currentDay >= apr1 && currentDay <= oct31 ) {
                                    //Apr 1 - Oct 31
                                    if( $('#date-'+json.dates[i].date).attr('class') ) {
                                      ( $('#date-'+json.dates[i].date).attr('class').indexOf('saturday')>-1 || $('#date-'+json.dates[i].date).attr('class').indexOf('sunday')>-1 ) ? $('#date-'+json.dates[i].date+' .insivia-frmp-calendar-day-events').html('<li class="starting-at">Starting at $'+json.facility.rental_rates.rental_rates[1].weekend_cost+'</li>') : $('#date-'+json.dates[i].date+' .insivia-frmp-calendar-day-events').html('<li class="starting-at">Starting at $'+json.facility.rental_rates.rental_rates[1].weekday_cost+'</li>');
                                    }
                Severity: Major
                Found in tribute_files/insivia-frmp-script.js and 1 other location - About 1 day to fix
                tribute_files/insivia-frmp-script.js on lines 3297..3312

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

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

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

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

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

                Refactorings

                Further Reading

                Severity
                Category
                Status
                Source
                Language