wcp1231/another-mongoose-statemachine

View on GitHub

Showing 2 of 2 total issues

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

module.exports = function (schema, options) {
  var states = options.states;
  var transitions = options.transitions;
  var stateNames = _.keys(states);
  var transitionNames = _.keys(transitions);
Severity: Major
Found in index.js - About 4 hrs to fix

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

      function staticTransitionize(transitionName) {
        return function(id, callback) {
          var Model = this;
          var transition = transitions[transitionName];
          var enter = states[transition.to].enter;
    Severity: Major
    Found in index.js - About 2 hrs to fix
      Severity
      Category
      Status
      Source
      Language