mirror of
https://github.com/AykutSarac/jsoncrack.com.git
synced 2025-01-12 19:02:53 +08:00
fix old premium check
This commit is contained in:
parent
21150a21c4
commit
005811bb0b
@ -81,7 +81,7 @@ const useFile = create<FileStates & JsonActions>()((set, get) => ({
|
|||||||
useJson.getState().clear();
|
useJson.getState().clear();
|
||||||
},
|
},
|
||||||
setJsonSchema: jsonSchema => {
|
setJsonSchema: jsonSchema => {
|
||||||
if (useUser.getState().isPremium()) set({ jsonSchema });
|
if (useUser.getState().premium) set({ jsonSchema });
|
||||||
},
|
},
|
||||||
setFile: fileData => {
|
setFile: fileData => {
|
||||||
set({ fileData });
|
set({ fileData });
|
||||||
|
@ -35,7 +35,7 @@ const useModal = create<ModalState & ModalActions>()(set => ({
|
|||||||
|
|
||||||
if (authModals.includes(modal) && !user.isAuthenticated) {
|
if (authModals.includes(modal) && !user.isAuthenticated) {
|
||||||
return set({ login: true });
|
return set({ login: true });
|
||||||
} else if (premiumModals.includes(modal) && !user.isPremium()) {
|
} else if (premiumModals.includes(modal) && !user.premium) {
|
||||||
return set({ premium: true });
|
return set({ premium: true });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user