langateam/node-plv8

View on GitHub

Showing 6 of 6 total issues

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

module.exports = function(knex) {
  return knex.raw(`
      SET client_min_messages TO WARNING;
      DO $$ BEGIN
        CREATE EXTENSION IF NOT EXISTS plv8;
Severity: Minor
Found in lib/bootstrap.js - About 2 hrs to fix

    Function install has 47 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

      install ({ modulePath, moduleName }, compact = true) {
        return this.init()
        .then(() => {
          return new Promise((resolve, reject) => {
            browserify({ ignoreMissing: true, standalone: moduleName })
    Severity: Minor
    Found in index.js - About 1 hr to fix

      Function createStoredProcedure has 36 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function createStoredProcedure (name, paramObj, ret, func, init) {
        const signature = _.map(paramObj, (type, key) => {
          return {
            arg: (type === 'v8.json') ? `JSON.parse('${key}')` : key,
            param: `${key} ${type}`
      Severity: Minor
      Found in lib/bootstrap.js - About 1 hr to fix

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

          eval (f, compact = true) {
            let es5
            const template = `
              (function () {
                try {
        Severity: Minor
        Found in index.js - About 1 hr to fix

          Function init has 30 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

            init () {
              return this.knex('pg_catalog.pg_namespace').select().where({ nspname: 'v8' })
                .then(([ schema ]) => {
                  if (schema) {
                    return
          Severity: Minor
          Found in index.js - About 1 hr to fix

            Function createStoredProcedure has 5 arguments (exceeds 4 allowed). Consider refactoring.
            Open

            function createStoredProcedure (name, paramObj, ret, func, init) {
            Severity: Minor
            Found in lib/bootstrap.js - About 35 mins to fix
              Severity
              Category
              Status
              Source
              Language