Browse Source

replace abandoned findit by findit2

Herbert Vojčík 8 years ago
parent
commit
76f5d85111
2 changed files with 3 additions and 2 deletions
  1. 2 1
      lib/config-builder.js
  2. 1 1
      package.json

+ 2 - 1
lib/config-builder.js

@@ -1,7 +1,7 @@
 var path = require('path'),
     url = require('url'),
     _ = require('lodash'),
-    findit = require('findit'),
+    findit = require('findit2'),
     fs = require('fs');
 
 function eachConfigFile(root, callback) {
@@ -47,6 +47,7 @@ function transformPaths(json, root, file, dirs) {
             switch (typeof pathValue) {
                 case "string":
                     array[key] = url.resolve(dir, pathValue) || ".";
+                    if (array[key].slice(-1) === "/") array[key] = array[key].slice(0, -1);
                     break;
                 case "object":
                     Array.isArray(pathValue) && transformPathArray(pathValue);

+ 1 - 1
package.json

@@ -24,7 +24,7 @@
     "node": ">=0.10.0"
   },
   "dependencies": {
-    "findit": "^2.0.0",
+    "findit2": "^2.2.3",
     "lodash": "^2.4.1"
   }
 }