Inist-CNRS / lodex

Linked Open Data EXperiment
https://www.lodex.fr/
Other
54 stars 12 forks source link

Cannot read properties of undefined (reading 'startsWith') #2213

Open touv opened 5 days ago

touv commented 5 days ago

Décrire le bogue instance bloquée au démarrage, il est impossible d'afficher et d'accèder aux interfaces

Reproduire inconnu

Captures d'écran image

Contexte supplémentaire

 TypeError: Cannot read properties of undefined (reading 'startsWith')
      at BreadcrumbItem (/app/src/app/js/public/breadcrumb/BreadcrumbItem.js:40:19)
      at d (/app/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:36:498)
      at $a (/app/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:39:16)
      at a.b.render (/app/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:44:476)
      at a.b.read (/app/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:44:18)
      at renderToString (/app/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:54:364)
      at /app/src/api/controller/front.js:125:23
      at Object.renderStatic (/app/node_modules/aphrodite/lib/exports.js:53:20)
      at getPreloadedState (/app/src/api/controller/front.js:124:22)
      at processTicksAndRejections (node:internal/process/task_queues:95:5)
      at handleRender (/app/src/api/controller/front.js:170:42)
      at /app/src/api/controller/front.js:244:16
      at /app/src/api/controller/front.js:230:16
      at /app/node_modules/koa-mount/index.js:52:26
      at /app/node_modules/koa-mount/index.js:52:26
      at /app/node_modules/koa-mount/index.js:52:26
      at configTenantInstanceMiddleware (/app/src/api/controller/index.js:117:5)
      at /app/src/api/services/repositoryMiddleware.js:27:5
      at /app/src/api/controller/index.js:73:5
      at /app/node_modules/koa-mount/index.js:52:26
      at mongoRootAdminClient (/app/src/api/services/repositoryMiddleware.js:38:5)
touv commented 5 days ago

see https://github.com/Inist-CNRS/lodex/blob/master/src/app/js/public/breadcrumb/BreadcrumbItem.js#L40

touv commented 5 days ago

image

touv commented 5 days ago

le problème apparait quand il manque le champ url dans un item du "breadcrumb": []