Skip to content

Commit 470575f

Browse files
fix: wrapper element related
1 parent 3442c52 commit 470575f

3 files changed

Lines changed: 5 additions & 2 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "strapi-plugin-navigation",
3-
"version": "3.3.4",
3+
"version": "3.3.5-beta.1",
44
"description": "Strapi - Navigation plugin",
55
"strapi": {
66
"name": "navigation",

server/src/content-types/navigation-item/schema.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ export default {
7575
related: {
7676
type: 'relation',
7777
relation: 'morphToMany',
78-
required: true,
78+
required: false,
7979
configurable: false,
8080
},
8181
parent: {

server/src/utils/migration.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@ export const removeNavigationsWithoutDefaultLocale = async (context: { strapi: C
77
limit: Number.MAX_SAFE_INTEGER,
88
});
99
const defaultLocale = await context.strapi.plugin('i18n').service('locales').getDefaultLocale();
10+
if (!defaultLocale) {
11+
return;
12+
}
1013
await Promise.all(
1114
allNavigations.map(async (navigation) => {
1215
const root = allNavigations.find(

0 commit comments

Comments
 (0)