Skip to content

Commit

Permalink
fix(remix): Null-check options
Browse files Browse the repository at this point in the history
  • Loading branch information
onurtemizkan committed Mar 6, 2025
1 parent 9db024d commit a7d984d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/remix/src/server/errors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,9 @@ export async function errorHandleDataFunction(
return handleCallbackErrors(
async () => {
if (name === 'action' && span) {
const options = getClient()?.getOptions() as RemixOptions;
const options = getClient()?.getOptions() as RemixOptions | undefined;

if (options.sendDefaultPii && options.captureActionFormDataKeys) {
if (options?.sendDefaultPii && options.captureActionFormDataKeys) {
await storeFormDataKeys(args, span);
}
}
Expand Down

0 comments on commit a7d984d

Please sign in to comment.