Update
This commit is contained in:
@@ -133,7 +133,7 @@ const useMediaStore = create(
|
||||
set({ keywords: [] });
|
||||
},
|
||||
|
||||
init: async () => {
|
||||
init: async (skipCache = false) => {
|
||||
const state = get();
|
||||
|
||||
// Skip API call completely if ALL initial values were set via props
|
||||
@@ -142,7 +142,12 @@ const useMediaStore = create(
|
||||
}
|
||||
|
||||
try {
|
||||
const response = await axiosInstance.post(route('api.app.init'));
|
||||
const params = {};
|
||||
if (skipCache) {
|
||||
params.sc = '1';
|
||||
}
|
||||
|
||||
const response = await axiosInstance.post(route('api.app.init'), params);
|
||||
|
||||
if (response?.data?.success?.data?.init) {
|
||||
const updates = {};
|
||||
|
||||
Reference in New Issue
Block a user