stellar/stellar-wallet — pull request #55 by bartekn (2014-11-12 20:04:18+00:00)
Title: Cron and grace period emails

This PR adds ability to send periodic emails to users with initialized TOTP grace period. But it also introduces support for running other time-based scripts. `cron.js` should be executed every minute using cron (`* * * * *`). We're checking if a specific function has to be run inside a script. It's to prevent updating crontab every time we need to add a new job. We're using [later.js](https://github.com/bunkat/later) to check if we should fire a function.

PS. Adding some tests for `walletV2.getWithTotpGracePeriodInitiated` would be a good idea.
PS2. @nullstyle, it would be great to be able to extend [stex](https://github.com/stellar/stex/blob/master/bin/stex) with additional commands. It could be injectable like initializers. Then we could avoid writing code that initializes stex and run it like: `stex cron`. But that's just a sidenote for the future.