thiagofm/memcached-manager

View on GitHub

Showing 110 of 168 total issues

Avoid deeply nested control flow statements.
Open

                                    if (arguments[i] === undef) {
                                        match[i] = undef;
                                    }
Severity: Major
Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

    Avoid deeply nested control flow statements.
    Open

                        if (e.shiftKey) {
                            self.insert('\n');
                        } else {
                            if (history && command && !mask &&
                                ((typeof options.historyFilter == 'function' &&
    Severity: Major
    Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

      Avoid deeply nested control flow statements.
      Open

                                          if (new_object) {
                                              $.extend(object, new_object);
                                          }
      Severity: Major
      Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

        Avoid deeply nested control flow statements.
        Open

                        } else if (e.which === 8) { //backspace
                            if (reverse_search) {
                                reverse_search_string = reverse_search_string.slice(0, -1);
                                draw_reverse_prompt();
                            } else {
        Severity: Major
        Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

          Avoid deeply nested control flow statements.
          Open

                                      if (last[last.length-1] !== ']') {
                                          prev_format = last.match(format_begin_re)[1];
                                          output_line += ']';
                                      } else if (output_line.match(format_last_re)) {
                                          var line_len = output_line.length;
          Severity: Major
          Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

            Avoid deeply nested control flow statements.
            Open

                                    if (line[j] === '&') { // treat entity as one character
                                        var m = line.substring(j).match(/^(&[^;]+;)/);
                                        if (!m) {
                                            // should never happen if used by terminal, because
                                            // it always calls $.terminal.encode before this function
            Severity: Major
            Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                                      } else if (type === 'object') {
                                          $.extend(object, first);
                                          recur(rest, success);
                                      }
              Severity: Major
              Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                Avoid deeply nested control flow statements.
                Open

                                            if (matched[0].charAt(j) !== matched[i].charAt(j)) {
                                                break loop;
                                            }
                Severity: Major
                Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                  Avoid deeply nested control flow statements.
                  Open

                                                      if (!silent) {
                                                          try {
                                                              settings.onTerminalChange(self);
                                                          } catch (e) {
                                                              display_exception(e, 'onTerminalChange');
                  Severity: Major
                  Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                    Avoid deeply nested control flow statements.
                    Open

                                                    if (num_lines === 3) {
                                                        before.before('<div>' + $.terminal.encode(array[0], true) +
                                                                      '</div>');
                                                        draw_cursor_line(array[1], position-first_len-1);
                                                        after.after('<div class="clear">' +
                    Severity: Major
                    Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                      Avoid deeply nested control flow statements.
                      Open

                                                      if (result === false) {
                                                          lines = lines.slice(0, position).
                                                              concat(lines.slice(position+1));
                                                      } else {
                                                          lines = lines.slice(0, position).
                      Severity: Major
                      Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                        Function filesize has 6 arguments (exceeds 4 allowed). Consider refactoring.
                        Open

                          humanize.filesize = function(filesize, kilo, decimals, decPoint, thousandsSep, suffixSep) {
                        Severity: Minor
                        Found in lib/public/javascripts/humanize.js - About 45 mins to fix

                          Avoid deeply nested control flow statements.
                          Open

                                                  for (i=strings.length-1; i>0; i--) {
                                                      // treat escape space as part of the string
                                                      if (strings[i-1][strings[i-1].length-1] == '\\') {
                                                          string = strings[i-1] + ' ' + string;
                                                      } else {
                          Severity: Major
                          Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                            Function add has 6 arguments (exceeds 4 allowed). Consider refactoring.
                            Open

                                        add: function(element, interval, label, fn, times, belay) {
                            Severity: Minor
                            Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                              Avoid deeply nested control flow statements.
                              Open

                                                      while ((replacement_field = replacement_field.substring(field_match[0].length)) !== '') {
                                                          if ((field_match = /^\.([a-z_][a-z_\d]*)/i.exec(replacement_field)) !== null) {
                                                              field_list.push(field_match[1]);
                                                          }
                                                          else if ((field_match = /^\[(\d+)\]/.exec(replacement_field)) !== null) {
                              Severity: Major
                              Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                                Avoid deeply nested control flow statements.
                                Open

                                                            if (output_line.match(']')) {
                                                                prev_format = '';
                                                            }
                                Severity: Major
                                Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                                  Avoid deeply nested control flow statements.
                                  Open

                                                              if (fn.$timerID) {
                                                                  window.clearInterval(timers[label][fn.$timerID]);
                                                                  delete timers[label][fn.$timerID];
                                                              }
                                  Severity: Major
                                  Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                                    Avoid deeply nested control flow statements.
                                    Open

                                                        if (terminals.length() > 1) {
                                                            self.focus(false);
                                                            return false;
                                                        }
                                    Severity: Major
                                    Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                                      Avoid deeply nested control flow statements.
                                      Open

                                                      } else if (e.which === 34) { // PAGE DOWN
                                                          self.scroll(self.height());
                                                      } else if (e.which === 33) { // PAGE UP
                                                          self.scroll(-self.height());
                                                      } else {
                                      Severity: Major
                                      Found in lib/public/javascripts/jquery-terminal.js - About 45 mins to fix

                                        Consider simplifying this complex logical expression.
                                        Open

                                            } else if (c === 0 || (c >= 5 && c <= 20) || (c % 10 >= 5 && c % 10 <= 9) || (c % 10 === 0) ) {
                                              return 0;
                                            } else if (c === 1 || c % 10 === 1) {
                                              return 1;
                                            } else if (c > 1) {
                                        Severity: Major
                                        Found in lib/public/javascripts/humanize_duration.js - About 40 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language