Skip to content

Commit 8d2331c

Browse files
author
benholloway
committed
fixed server and watch tasks not respecting angularity.json port config
1 parent c75e9f5 commit 8d2331c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/config/defaults.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,10 +143,10 @@ function commit() {
143143
*/
144144
function readFile(filePath, field) {
145145
if (filePath && fs.existsSync(filePath)) {
146-
var data = fs.readFileSync(filePath);
146+
var data = fs.readFileSync(filePath).toString();
147147
try {
148148
var json = JSON.parse(data)
149-
return field ? (json[field] || {}) : field;
149+
return field ? (json[field] || {}) : json;
150150
} catch(error) {
151151
throw new Error('Unparsable json file: ' + filePath);
152152
}

0 commit comments

Comments
 (0)