Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

timexe

Package Overview
Dependencies
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

timexe - npm Package Compare versions

Comparing version 1.0.2 to 1.0.3

2

package.json
{
"name": "timexe",
"version": "1.0.2",
"version": "1.0.3",
"description": "Yet another cron clone – but this one is better :o) - new improved syntax – milliseconds resolution – both for node JS and browser",

@@ -5,0 +5,0 @@ "main": "timexe.js",

@@ -163,4 +163,6 @@ # Timexe - A Cron-like Timer and scheduler witn milliseconds resolution

## Change log
1.0.2 Temp bugfix of mismatchd ID. Creates a sligt leak. To be fixed properly ASAP
1.0.3 Bugfix: mismatched ID
1.0.2 Temp bugfix of mismatched ID.
1.0.1 Documentation

@@ -167,0 +169,0 @@

@@ -127,5 +127,29 @@ /*============================================================================*\

/*============================================================================*\
Internal functions
\*============================================================================*/
// Globals
timexe.list=[];
last_id=0;
// Constants
var limit = [
[1970, 3000]
,[1, 12]
,[1, 31]
,[0, 23]
,[0, 59]
,[0, 59]
,[0, 999]
,[0, 999]
,[0, 999]
,[0, 999]
,[1, 7] // Week day
,[1, 366] // Day of year
,[1, 53] // Week number
];
var fieldName=['year', 'month', 'day', 'hour', 'min', 'sec', 'ms','weekday','yearday','week'];
// Job object

@@ -160,3 +184,4 @@ // timex: Time expression

var id = timexe.list.push({
var id = ++last_id;
timexe.list[id]={
timex: timex

@@ -166,3 +191,3 @@ ,action: action

,timeoutShortened: false // Define the timeout Shortened flag
}) -1;
};

@@ -179,3 +204,3 @@ // Start timed execution

clearTimeout(timexe.list[id].timer);
timexe.list.splice(id,1);
delete timexe.list[id];
return {"result":"ok","error":""};

@@ -191,27 +216,2 @@ }

/*============================================================================*\
Internal functions
\*============================================================================*/
// Globals
timexe.nextId=1;
// Constants
var limit = [
[1970, 3000]
,[1, 12]
,[1, 31]
,[0, 23]
,[0, 59]
,[0, 59]
,[0, 999]
,[0, 999]
,[0, 999]
,[0, 999]
,[1, 7] // Week day
,[1, 366] // Day of year
,[1, 53] // Week number
];
var fieldName=['year', 'month', 'day', 'hour', 'min', 'sec', 'ms','weekday','yearday','week'];
// start on load

@@ -244,3 +244,3 @@

if(result.time < now){
//timexe.remove(id);
timexe.remove(id);
return "time expression did not produce a valid future time";

@@ -247,0 +247,0 @@ }

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