From a2820ac98f84c1b219b7d79366cf706b612d52d1 Mon Sep 17 00:00:00 2001 From: srfrnk Date: Sat, 28 Jul 2018 19:25:02 +0300 Subject: [PATCH] fix: add preinstall step for aspell + fixed #7 --- index.js | 4 ++++ package.json | 1 + 2 files changed, 5 insertions(+) diff --git a/index.js b/index.js index 9cad003..41f03ee 100644 --- a/index.js +++ b/index.js @@ -31,6 +31,10 @@ module.exports = function (options) { function check (file, enc, callback) { /*jshint validthis:true */ var self = this; + if(!file.contents) + { + return callback(); + } var contents = file.contents.toString('utf-8'); // Remove all line breaks and add a circumflex in order to disable 'pipe mode'. diff --git a/package.json b/package.json index 82d222b..4442bb0 100644 --- a/package.json +++ b/package.json @@ -9,6 +9,7 @@ "license": "MIT", "main": "index.js", "scripts": { + "preinstall": "echo 'This npm package requires installing aspell for development:' && sudo apt install aspell", "test": "gulp" }, "repository": {