jeremydenoun/iprofilesync

View on GitHub
src/checker/ssh.js

Summary

Maintainability
C
1 day
Test Coverage

Function check has 109 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        SshCheck.prototype.check = function(host, data, callback) {
            data = _.extend(this.options, data);

            var errored, f, k, key, port, ports, ran, succeeded, user, users, _i, _j, _len, _len1, _ref, _users, _results;
            if (data.hasOwnProperty('checker_private_key') && data.checker_private_key) {
Severity: Major
Found in src/checker/ssh.js - About 4 hrs to fix

    Function check_nodes has 64 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

            SshCheck.prototype.check_nodes = function(hash, callback) {
                var done, key, _results, data;
    
                if (hash instanceof Array) {
                    data = hash;
    Severity: Major
    Found in src/checker/ssh.js - About 2 hrs to fix

      Avoid deeply nested control flow statements.
      Open

                                              if (!sent) {
                                                  callback(new Error("No tentative succeeded"));
                                              }
      Severity: Major
      Found in src/checker/ssh.js - About 45 mins to fix

        Avoid deeply nested control flow statements.
        Open

                                                if (!sent) {
                                                    callback(err);
                                                }
        Severity: Major
        Found in src/checker/ssh.js - About 45 mins to fix

          There are no issues that match your filters.

          Category
          Status