fix: handle network connectivity in DUI (#80)

* error handler

* top-level handling

* internet check

* pass other network errors

---------

Co-authored-by: Oğuzhan Koral <45078678+oguzhankoral@users.noreply.github.com>
This commit is contained in:
Dogukan Karatas
2026-01-12 15:51:47 +01:00
committed by GitHub
parent 305b100d34
commit 19f306756c
2 changed files with 8 additions and 8 deletions
+1
View File
@@ -6920,6 +6920,7 @@ export type WorkspacePermissionChecks = {
canReadSecuritySettings: PermissionCheckResult;
canReadWorkspaceIssueLabels: PermissionCheckResult;
canRemoveUser: PermissionCheckResult;
canUseAdminSupportTools: PermissionCheckResult;
canUseExperimentalDashboardFeatures: PermissionCheckResult;
};
+7 -8
View File
@@ -165,14 +165,13 @@ export const useAccountStore = defineStore('accountStore', () => {
// hostAppStore.setNotification(notification)
}
// if (res.networkError) {
// const notification: ToastNotification = {
// type: ToastNotificationType.Danger,
// title: 'Network Error',
// description: res.networkError.message
// }
// hostAppStore.setNotification(notification)
// }
if (res.networkError && !navigator.onLine) {
hostAppStore.setNotification({
type: ToastNotificationType.Danger,
title: 'No Internet Connection',
description: 'Please check your network connection and try again.'
})
}
})
const link = splitLink(