frisb/fdboost

View on GitHub

Showing 18 of 55 total issues

Function exports has 196 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  module.exports = function(fdb, debug) {
    var RangeReader, db, iterate, transactionalIterate;
    db = fdb.open();

    /**
Severity: Major
Found in lib/enhance/rangereader.js - About 7 hrs to fix

    Function exports has 142 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

      module.exports = function(fdb, debug) {
        var count, execute;
        execute = function(tr, options, callback) {
          var begin, end;
          begin = options.begin, end = options.end;
    Severity: Major
    Found in lib/enhance/database/countkeys.js - About 5 hrs to fix

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

        module.exports = function(fdboost) {
          var fdb;
          fdb = fdboost.fdb;
          return fdb.serializable = function(serialize, deserialize) {
            var Serializer, set, transactionalGet, transactionalSet;
      Severity: Major
      Found in lib/enhance/serializable.js - About 2 hrs to fix

        Function serializable has 66 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            return fdb.serializable = function(serialize, deserialize) {
              var Serializer, set, transactionalGet, transactionalSet;
              set = function(tr, arr, callback) {
                var e, i, kv, len, ret, s, _i, _len, _results;
                len = arr.length;
        Severity: Major
        Found in lib/enhance/serializable.js - About 2 hrs to fix

          Function exports has 55 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

            module.exports = function(fdb, debug) {
              var enhanceDatabase, enhanceTransaction, enhancements, open;
              enhancements = {
                getLastKey: require('./getlastkey')(fdb, debug),
                countKeys: require('./countkeys')(fdb, debug)
          Severity: Major
          Found in lib/enhance/database/index.js - About 2 hrs to fix

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

              module.exports = function(encoding) {
                var IntegerAdapter;
                return IntegerAdapter = (function(_super) {
                  __extends(IntegerAdapter, _super);
            
            
            Severity: Minor
            Found in lib/enhance/encoding/adapters/integer.js - About 1 hr to fix

              Function execute has 42 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                    RangeReader.prototype.execute = function(tr, iteratorType) {
                      var complete, pastVersionCatchingCallback, toBeContinued, txi;
                      if (typeof tr === 'string') {
                        iteratorType = tr;
                        tr = db;
              Severity: Minor
              Found in lib/enhance/rangereader.js - About 1 hr to fix

                Function exports has 40 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                  module.exports = function(fdb, debug) {
                
                    /**
                     * The callback format for the Transaction~getLastKey method
                     * @callback Transaction~getLastKeyCallback
                Severity: Minor
                Found in lib/enhance/database/getlastkey.js - About 1 hr to fix

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

                    module.exports = function(encoding) {
                      return {
                        types: require('../typecodes'),
                        Undefined: require('./undefined')(encoding),
                        String: require('./string')(encoding),
                  Severity: Minor
                  Found in lib/enhance/encoding/adapters/index.js - About 1 hr to fix

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

                          RangeReader.prototype.getIterator = function(tr, callback) {
                            var begin, iterator, options, ts;
                            debug(function(writer) {
                              return writer.log('getIterator');
                            });
                    Severity: Minor
                    Found in lib/enhance/rangereader.js - About 1 hr to fix

                      Function exports has 37 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                        module.exports = function(encoding) {
                          var ArrayAdapter;
                          return ArrayAdapter = (function(_super) {
                            __extends(ArrayAdapter, _super);
                      
                      
                      Severity: Minor
                      Found in lib/enhance/encoding/adapters/array.js - About 1 hr to fix

                        Function RangeReader has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                              function RangeReader(options) {
                                RangeReader.__super__.constructor.call(this);
                                this.begin = options.begin;
                                this.end = options.end;
                                this.marker = null;
                        Severity: Minor
                        Found in lib/enhance/rangereader.js - About 1 hr to fix

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

                            module.exports = function(fdb) {
                              var enhancements, fn, fnName, _results;
                              enhancements = {
                                packEncoded: function(arr, prefix) {
                                  var encodedArr, item;
                          Severity: Minor
                          Found in lib/enhance/tuple.js - About 1 hr to fix

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

                              module.exports = function(encoding) {
                                var DateTimeAdapter;
                                return DateTimeAdapter = (function(_super) {
                                  __extends(DateTimeAdapter, _super);
                            
                            
                            Severity: Minor
                            Found in lib/enhance/encoding/adapters/datetime.js - About 1 hr to fix

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

                                  'get': function(value) {
                                    switch (typeof value) {
                                      case 'undefined':
                                        return this.undefined;
                                      case 'string':
                              Severity: Minor
                              Found in lib/enhance/encoding/typecodes.js - About 1 hr to fix

                                Function get has 28 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                      get: function() {
                                        var factory;
                                        factory = function(version) {
                                          if (typeof version === 'object') {
                                            return factory.use(version);
                                Severity: Minor
                                Found in lib/index.js - About 1 hr to fix

                                  Avoid too many return statements within this function.
                                  Open

                                              return this.array;
                                  Severity: Major
                                  Found in lib/enhance/encoding/typecodes.js - About 30 mins to fix

                                    Avoid too many return statements within this function.
                                    Open

                                                return this.object;
                                    Severity: Major
                                    Found in lib/enhance/encoding/typecodes.js - About 30 mins to fix
                                      Severity
                                      Category
                                      Status
                                      Source
                                      Language