Skip to content

Commit

Permalink
fix Cannot read properties of undefined (reading 'collection')
Browse files Browse the repository at this point in the history
  • Loading branch information
Ratatinator97 committed Jul 18, 2024
1 parent 6958dd7 commit 27b78ab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion components/pictos/pictoBar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ export default {
const sidebarSpeech = this.$store.getters.getSpeech.filter(
(picto) => picto.sidebar && picto.collection
);
if (pictoSpeech[pictoSpeech.length - 1].collection) {
if (pictoSpeech[pictoSpeech.length - 1] && pictoSpeech[pictoSpeech.length - 1].collection) {
if (pictoSpeech[pictoSpeech.length - 1].sidebar) {
if (sidebarSpeech.length <= 1) {
if (this.publicMode) {
Expand Down

0 comments on commit 27b78ab

Please sign in to comment.