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

TypeError: e.workingVersion is undefined #1234

Open
sentry-io bot opened this issue Jan 30, 2025 · 2 comments
Open

TypeError: e.workingVersion is undefined #1234

sentry-io bot opened this issue Jan 30, 2025 · 2 comments

Comments

@sentry-io
Copy link

sentry-io bot commented Jan 30, 2025

Sentry Issue: STYLO-FRONT-H

TypeError: e.workingVersion is undefined
  at vn (/assets/Articles-B2fueIcs.js:297:5063)
  at Cs (/assets/index-DTBADyn4.js:41:17824)
  at ch (/assets/index-DTBADyn4.js:43:3138)
  at zg (/assets/index-DTBADyn4.js:43:45282)
  at jg (/assets/index-DTBADyn4.js:43:40189)
...
(6 additional frame(s) were not displayed)
@ggrossetie
Copy link
Collaborator

D'après la stacktrace, l'erreur vient de :

bib={article.workingVersion.bibPreview}

Cela dit, je ne comprends pas comment workingVersion peut être undefined. Est-ce qu'on ajoute un null-safe (?) ?

article.workingVersion?.bibPreview

@thom4parisot Est-ce que tu vois un cas où workingVersion pourrait être undefined ?

@thom4parisot
Copy link
Member

Quand l'article n'est pas encore chargé (entre le moment où on clique et c'est déplié) ou si on s'est planté quelque part sur ce qu'on assigne à workingVersion ?

Ça serait plus simple si on passait l'article au composant d'export. Ou si le composant d'export n'était instancé que lorsqu'on exporte vraiment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants