HEX
Server: Apache/2.4.52 (Ubuntu)
System: Linux ip-10-0-8-47 6.8.0-1021-aws #23~22.04.1-Ubuntu SMP Tue Dec 10 16:31:58 UTC 2024 aarch64
User: ubuntu (1000)
PHP: 8.1.2-1ubuntu2.22
Disabled: NONE
Upload Files
File: /var/www/javago-nodeserver-hotfixes/node_modules/node-schedule/UPGRADING.md
## Upgrading to new node-schedule versions

### Upgrading to version 2.0.0+

* Node.js versions older than 6 are no longer supported, please update your environment before upgrading.
* In order to prevent memory leaks, one-off jobs (targeted to be executed at an exact date) cannot be rescheduled by name, as reference to them is no longer stored indefinitely. If you want to keep rescheduling them, make sure to store reference to the initial job.
* The `scheduleJob()` method no longer supports passing an object with the job method. If you were using an object, pass the job method directly.  

  E.g. code that previously looked like this:
  ```javascript
  const obj = {
   execute() {}
  };
  Scheduler.scheduleJob(obj);
  ```
  should be changed to something like this:
  ```javascript
  function execute() {}
  Scheduler.scheduleJob(execute);
  ```