Socket
Socket
Sign inDemoInstall

watchr

Package Overview
Dependencies
Maintainers
1
Versions
122
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

watchr - npm Package Compare versions

Comparing version 2.3.8 to 2.3.9

32

out/lib/watchr.js

@@ -241,18 +241,20 @@ // Generated by CoffeeScript 1.6.1

config = this.config;
if (this.cacheTimeout != null) {
clearTimeout(this.cacheTimeout);
if (config.duplicateDelay) {
if (this.cacheTimeout != null) {
clearTimeout(this.cacheTimeout);
}
this.cacheTimeout = setTimeout(function() {
me.cachedEvents = [];
return me.cacheTimeout = null;
}, config.duplicateDelay);
if ((_ref = this.cachedEvents) == null) {
this.cachedEvents = [];
}
thisEvent = args.toString();
if (__indexOf.call(this.cachedEvents, thisEvent) >= 0) {
this.log('debug', "event ignored on " + this.path + " due to duplicate:", args);
return this;
}
this.cachedEvents.push(thisEvent);
}
this.cacheTimeout = setTimeout(function() {
me.cachedEvents = [];
return me.cacheTimeout = null;
}, config.duplicateDelay);
if ((_ref = this.cachedEvents) == null) {
this.cachedEvents = [];
}
thisEvent = args.toString();
if (__indexOf.call(this.cachedEvents, thisEvent) >= 0) {
this.log('debug', "event ignored on " + this.path + " due to duplicate:", args);
return this;
}
this.cachedEvents.push(thisEvent);
this.emit.apply(this, args);

@@ -259,0 +261,0 @@ return this;

{
"name": "watchr",
"version": "2.3.8",
"version": "2.3.9",
"description": "Better file system watching for Node.js",

@@ -5,0 +5,0 @@ "homepage": "https://github.com/bevry/watchr",

@@ -21,3 +21,3 @@ ## Watchr: better file system watching for Node.js [![Build Status](https://secure.travis-ci.org/bevry/watchr.png?branch=master)](http://travis-ci.org/bevry/watchr)

- `persistent` (optional, defaults to `true`) whether or not we should keep the node process alive for as long as files are still being watched
- `duplicateDelay` (optional, defaults to `1000`) sometimes events will fire really fast, this delay is set in place so we don't fire the same event within the timespan
- `duplicateDelay` (optional, defaults to `1000`) sometimes events will fire really fast, this delay is set in place so we don't fire the same event within the timespan. Set to falsey to perform no duplicate detection.
- `preferredMethods` (optional, defaults to `['watch','watchFile']`) which order should we prefer our watching methods to be tried?

@@ -24,0 +24,0 @@ - `ignorePaths` (optional, defaults to `false`) an array of full paths to ignore

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc