Only watch sass if folder exists

Closes #1249
This commit is contained in:
Vincent Prouillet 2020-12-14 22:22:58 +01:00
parent 2d71a79bbe
commit 26b8ec66ac

View file

@ -267,7 +267,7 @@ pub fn serve(
let should_watch = match mode {
WatchMode::Required => true,
WatchMode::Optional => watch_path.exists(),
WatchMode::Condition(b) => b,
WatchMode::Condition(b) => b && watch_path.exists(),
};
if should_watch {
watcher