Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(protocol-designer): deprecate Formik, migrate to React-Hook-Form #14408

Closed
wants to merge 16 commits into from
Closed
Prev Previous commit
Next Next commit
fix getParsedAnalysisFromPath test error
  • Loading branch information
brenthagen authored and jerader committed Feb 1, 2024
commit 2d7c769e70cec97c72205ce0a4379291bbef5181
10 changes: 5 additions & 5 deletions app-shell/src/protocol-storage/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,11 @@ export const getParsedAnalysisFromPath = (
try {
return fse.readJsonSync(analysisPath)
} catch (error) {
if (error instanceof Error) {
return createFailedAnalysis(
error?.message ?? 'protocol analysis file cannot be parsed'
)
}
const errorMessage =
error instanceof Error && error?.message != null
? error.message
: 'protocol analysis file cannot be parsed'
return createFailedAnalysis(errorMessage)
}
}

Expand Down