flarum/flarum-gulp

rename or delete file break watch task

Closed this issue · 1 comments

sijad commented

step to reproduce:

  1. run gulp watch
  2. try to rename or delete a file from src folder
  3. you will see something like this:
flarum/vendor/flarum/core/js/admin/node_modules/flarum-gulp/index.js:69
          delete cached.caches['modules' + prefix][event.path];
                                                        ^

TypeError: Cannot convert undefined or null to object
    at EventEmitter.<anonymous> (flarum/vendor/flarum/core/js/admin/node_modules/flarum-gulp/index.js:69:57)
    at emitOne (events.js:96:13)
    at EventEmitter.emit (events.js:188:7)
    at Gaze.<anonymous> (flarum/vendor/flarum/core/js/admin/node_modules/glob-watcher/index.js:17:11)
    at emitTwo (events.js:106:13)
    at Gaze.emit (events.js:191:7)
    at Gaze.emit (flarum/vendor/flarum/core/js/admin/node_modules/gaze/lib/gaze.js:129:32)
    at flarum/vendor/flarum/core/js/admin/node_modules/gaze/lib/gaze.js:389:18
    at Array.forEach (native)
    at flarum/vendor/flarum/core/js/admin/node_modules/gaze/lib/gaze.js:385:12

yeah this is annoying :(