changed CookieManager to StorageManager and abstracted the storage method