ff-stream-web

git clone git://archive.git.mtrnord.blog/MTRNord/ff-stream-web.git
Log | Files | Refs | README | LICENSE

commit 03fddd6a30b4f6334f4fa16fc49ffb2f46e6b997
parent c948d5d36de18c1696a809a482aa4f86a7c3e19e
Author: Konstantin Tarkus <koistya@gmail.com>
Date:   Thu, 28 Apr 2016 16:06:37 +0300

Merge pull request #632 from langpavel/fix-lint

[fix] Linter Error fixed
Diffstat:
Mtools/copy.js | 6++++--
1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/tools/copy.js b/tools/copy.js @@ -37,12 +37,14 @@ async function copy({ watch } = {}) { const watcher = await new Promise((resolve, reject) => { gaze('src/content/**/*.*', (err, val) => err ? reject(err) : resolve(val)); }); + const cp = async (file) => { const relPath = file.substr(path.join(__dirname, '../src/content/').length); await ncp(`src/content/${relPath}`, `build/content/${relPath}`); - } + }; + watcher.on('changed', cp); - watcher.on('added', cp); + watcher.on('added', cp); } }