Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit ba42ced

Browse files
committed
refactor(getVersion.js): remove unused parameters
The parameters have been unused since we moved most of the bower package dependencies to npm
1 parent ff2ce9d commit ba42ced

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

docs/config/services/getVersion.js

+4-5
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,10 @@ var path = require('canonical-path');
77
* Find the current version of the node module
88
*/
99
module.exports = function getVersion(readFilesProcessor) {
10-
var basePath = readFilesProcessor.basePath;
10+
var sourceFolder = path.resolve(readFilesProcessor.basePath, 'node_modules');
11+
var packageFile = 'package.json';
1112

12-
return function(component, sourceFolder, packageFile) {
13-
sourceFolder = path.resolve(basePath, sourceFolder || 'node_modules');
14-
packageFile = packageFile || 'package.json';
15-
return require(path.join(sourceFolder,component,packageFile)).version;
13+
return function(component) {
14+
return require(path.join(sourceFolder, component, packageFile)).version;
1615
};
1716
};

0 commit comments

Comments
 (0)