mirror of
https://github.com/Sagit-chu/flvx.git
synced 2026-10-07 02:06:38 +08:00
修复转发暂停问题 增加安卓apk
This commit is contained in:
@@ -3,22 +3,5 @@
|
||||
* 清除登录相关数据,但保留用户偏好设置(如主题)
|
||||
*/
|
||||
export const safeLogout = () => {
|
||||
// 需要保留的用户偏好设置
|
||||
const preservedSettings = {
|
||||
theme: localStorage.getItem('heroui-theme'),
|
||||
// 可以在这里添加其他需要保留的设置
|
||||
};
|
||||
|
||||
// 清除所有localStorage数据
|
||||
localStorage.clear();
|
||||
|
||||
// 恢复保留的设置
|
||||
Object.entries(preservedSettings).forEach(([key, value]) => {
|
||||
if (value) {
|
||||
if (key === 'theme') {
|
||||
localStorage.setItem('heroui-theme', value);
|
||||
}
|
||||
// 可以在这里添加其他设置的恢复逻辑
|
||||
}
|
||||
});
|
||||
};
|
||||
Reference in New Issue
Block a user