Update imgcache.js

wrapping this in a deviceready listener as is needed by line 535 to run without error. 

Without deviceready, an undefined will be returned by the getCordovaStorageType function.

This should be added in other places too but as this is the entry point it should suffice.