heatsync stability fixes #98
1 changed files with 5 additions and 1 deletions
6
start.js
6
start.js
|
|
@ -13,7 +13,11 @@ const {reg} = require("./src/matrix/read-registration")
|
|||
const passthrough = require("./src/passthrough")
|
||||
const db = new sqlite("ooye.db")
|
||||
|
||||
const sync = new HeatSync({watchFunction: fs.watchFile})
|
||||
const sync = new HeatSync({
|
||||
watchFunction: (path, options, listener) => fs.watchFile(path, options, (curr, prev) => {
|
||||
if (curr.mtimeMs !== prev.mtimeMs || curr.size !== prev.size) listener()
|
||||
})
|
||||
})
|
||||
|
||||
Object.assign(passthrough, {sync, db})
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue