Fix:2581 【商城小程序】历史搜索--退出重新登录后,历史搜索被清空
This commit is contained in:
@@ -33,8 +33,8 @@ function clearAll() {
|
|||||||
// uni.clearStorage()
|
// uni.clearStorage()
|
||||||
const res = uni.getStorageInfoSync()
|
const res = uni.getStorageInfoSync()
|
||||||
res.keys.map((item) => {
|
res.keys.map((item) => {
|
||||||
// 不要清除spread和redirect、页面埋点数据
|
// 不要清除spread和redirect、页面埋点和历史搜索数据数据,
|
||||||
if ([pageViewDataCacheKey, 'redirect', 'spread'].includes(item)) {
|
if ([pageViewDataCacheKey, 'redirect', 'spread', 'historyKey'].includes(item)) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
remove(item)
|
remove(item)
|
||||||
|
|||||||
Reference in New Issue
Block a user