Skip to content

Instantly share code, notes, and snippets.

@flurner
Last active December 27, 2015 07:39
Show Gist options
  • Select an option

  • Save flurner/7290267 to your computer and use it in GitHub Desktop.

Select an option

Save flurner/7290267 to your computer and use it in GitHub Desktop.
[Idea] Create a hash from Date and request ID.
var id = 123 // 'something from the database'
require('crypto')
.createHash('sha1')
.update(new Date() + id)
.digest('hex');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment