tweaked cache.js
fixed loading bar problems. added cache versioning