Bugfix and better expiration setting
Merge pull request #4 from mynameisfiber/master

Bugfixes and more reliable expiration policy