assemble-fs
Advanced tools
Comparing version 0.5.1 to 0.5.2
@@ -33,3 +33,3 @@ /*! | ||
function plugin(app) { | ||
if (!utils.isValid(app)) return; | ||
if (!utils.isValidApp(app, 'assemble-fs', ['app', 'views', 'collection'])) return; | ||
@@ -157,5 +157,5 @@ /** | ||
if (app.isApp) { | ||
view = collection.setView(file.path, file); | ||
view = collection.addView(file.path, file); | ||
} else if (app.isCollection || app.isViews) { | ||
view = app.setView(file.path, file); | ||
view = app.addView(file.path, file); | ||
} else if (app.isList) { | ||
@@ -162,0 +162,0 @@ view = app.setItem(file.path, file); |
{ | ||
"name": "assemble-fs", | ||
"description": "Assemble plugin to add methods to assemble for working with the file system, like src, dest, copy and symlink.", | ||
"version": "0.5.1", | ||
"version": "0.5.2", | ||
"homepage": "https://github.com/assemble/assemble-fs", | ||
@@ -26,4 +26,3 @@ "author": "Jon Schlinkert (https://github.com/jonschlinkert)", | ||
"extend-shallow": "^2.0.1", | ||
"is-registered": "^0.1.4", | ||
"is-valid-instance": "^0.1.0", | ||
"is-valid-app": "^0.1.0", | ||
"lazy-cache": "^2.0.1", | ||
@@ -30,0 +29,0 @@ "stream-combiner": "^0.2.2", |
23
utils.js
'use strict'; | ||
/** | ||
* Lazily required module dependencies | ||
*/ | ||
var utils = require('lazy-cache')(require); | ||
@@ -12,3 +8,3 @@ var fn = require; | ||
/** | ||
* Utils | ||
* Lazily required module dependencies | ||
*/ | ||
@@ -18,4 +14,3 @@ | ||
require('extend-shallow', 'extend'); | ||
require('is-registered'); | ||
require('is-valid-instance'); | ||
require('is-valid-app'); | ||
require('stream-combiner', 'combine'); | ||
@@ -27,16 +22,2 @@ require('through2', 'through'); | ||
/** | ||
* Return true if app is a valid instance | ||
*/ | ||
utils.isValid = function(app) { | ||
if (!utils.isValidInstance(app, ['app', 'views', 'collection'])) { | ||
return false; | ||
} | ||
if (utils.isRegistered(app, 'assemble-fs')) { | ||
return false; | ||
} | ||
return true; | ||
}; | ||
/** | ||
* Expose `utils` | ||
@@ -43,0 +24,0 @@ */ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7
7377
4
162
1
0
+ Addedis-valid-app@^0.1.0
+ Addeddebug@2.6.9(transitive)
+ Addedis-valid-app@0.1.2(transitive)
+ Addedms@2.0.0(transitive)
- Removedis-registered@^0.1.4
- Removedis-valid-instance@^0.1.0