Feature/hardening

-  Add better error handling for corrupt cache files
-  Only replace the /http and /https at the BEGINNING of the path, since for some webservices the /http is used in the url and we don't want to affect all occurances of it