fixed bug in expire files and made it run every 60 seconds in its own thread