clone from fastner/jasy-appcache