You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(POR-22666): handle platform FORM_RESPONSE errors in notification-center
Wrap notification fetch in try/catch so platform API errors like
'unable to perform action complete on FORM_RESPONSE' show a user-friendly
SilentError instead of an unhandled request error in Sentry.
Co-authored-by: Neil Raina <makeitraina@users.noreply.github.com>
Copy file name to clipboardExpand all lines: src/app/notification-center/page.tsx
+17-6Lines changed: 17 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -9,9 +9,9 @@ async function getNotificationDetail(token: string) {
9
9
constcopilot=newCopilotAPI(token)
10
10
consttokenPayload=awaitcopilot.getTokenPayload()
11
11
12
-
if(!tokenPayload)thrownewError('Failed to get token payload')
12
+
if(!tokenPayload?.notificationId)returnnull
13
13
14
-
returnawaitcopilot.getIUNotification(z.string().parse(tokenPayload.notificationId),tokenPayload.workspaceId)// notification "id" is expected in tokenPayload
0 commit comments