Skip to content

Commit 96e3175

Browse files
author
Alexander Yukal
committed
Merge branch 'dev'
2 parents c67aaf9 + 154c61e commit 96e3175

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

lib/gulp-json-loader.js

+4-2
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ const Util = require('util');
1414
const Path = require('path');
1515
const Fs = require('fs');
1616

17+
const PLUGIN_NAME = 'gulp-json-loader';
18+
1719
const APP_PATH = process.cwd();
1820
const DEFAULT_SOURCE_PATH = 'src';
1921
const BREAK_LINE = process.platform === 'win32' ? '\r\n' : '\n';
@@ -204,8 +206,8 @@ const factory = (options, testMode = false) => {
204206
const packagePath = Path.join(APP_PATH, 'package.json');
205207
const Package = require(packagePath);
206208

207-
options = Package.hasOwnProperty(Package.name)
208-
? Package[Package.name]
209+
options = Package.hasOwnProperty(PLUGIN_NAME)
210+
? Package[PLUGIN_NAME]
209211
: {};
210212
}
211213

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "gulp-json-loader",
33
"description": "A little tool for the gulp-data plugin. It useful for data loading in the development of HTML or the pug pages",
44
"author": "Alexander Yukal <yukal@email.ua>",
5-
"version": "1.2.0",
5+
"version": "1.2.1",
66
"main": "gulpfile.js",
77
"devDependencies": {
88
"chai": "^4.3.6",

0 commit comments

Comments
 (0)