Skip to content

Commit e4247fe

Browse files
committed
Fix refresh data bug
1 parent d99f149 commit e4247fe

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

site/src/xServices/pagination/paginationXService.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ export const paginationMachine =
4646
},
4747
{
4848
actions: {
49-
sendRefreshData: (_) => sendParent("REFRESH_DATA"),
49+
sendRefreshData: sendParent("REFRESH_DATA"),
5050
assignNextPage: assign({
5151
page: (context) => context.page + 1,
5252
}),

site/src/xServices/workspaces/workspacesXService.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,12 @@ export const workspacesMachine =
290290
},
291291
workspaces: {
292292
initial: "startingPagination",
293+
on: {
294+
REFRESH_DATA: {
295+
target: ".gettingWorkspaces",
296+
actions: "logRefresh"
297+
},
298+
},
293299
states: {
294300
startingPagination: {
295301
entry: "assignPaginationRef",
@@ -336,17 +342,11 @@ export const workspacesMachine =
336342
after: {
337343
"5000": {
338344
target: "#workspacesState.workspaces.gettingWorkspaces",
339-
actions: [],
340-
internal: false,
345+
internal: true
341346
},
342347
},
343348
},
344349
},
345-
on: {
346-
REFRESH_DATA: {
347-
target: ".gettingWorkspaces",
348-
},
349-
},
350350
},
351351
},
352352
},

0 commit comments

Comments
 (0)