diff --git a/smart-frontend/app/src/store/adh/rules/rulesActionsSlice.ts b/smart-frontend/app/src/store/adh/rules/rulesActionsSlice.ts index 5bdca029d4..3945ca9c66 100644 --- a/smart-frontend/app/src/store/adh/rules/rulesActionsSlice.ts +++ b/smart-frontend/app/src/store/adh/rules/rulesActionsSlice.ts @@ -77,7 +77,9 @@ const stopRule = createAsyncThunk('adh/rulesActions/stopRule', async (ruleId: nu } }); -const withFullUpdate = (name: string, dialogAction: ReturnType) => { +type DialogActionType = ReturnType; + +const withFullUpdate = (name: string, dialogAction: DialogActionType) => { return createAsyncThunk(name, async (payload: unknown, thunkAPI) => { await thunkAPI.dispatch(dialogAction(payload)).unwrap(); thunkAPI.dispatch(getRulesMetaInfo()); @@ -85,7 +87,7 @@ const withFullUpdate = (name: string, dialogAction: ReturnType) => { +const withMetaInfoUpdate = (name: string, dialogAction: DialogActionType) => { return createAsyncThunk(name, async (payload: unknown, thunkAPI) => { await thunkAPI.dispatch(dialogAction(payload)).unwrap(); thunkAPI.dispatch(getRulesMetaInfo());