Skip to content

Commit 4afe14b

Browse files
committed
fix: remove fallback
1 parent 57aa761 commit 4afe14b

File tree

1 file changed

+2
-22
lines changed

1 file changed

+2
-22
lines changed

src/welcome/admin.js

Lines changed: 2 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -167,17 +167,7 @@ const SEARCH_TREE = [
167167
groups: [
168168
{
169169
id: 'role-manager',
170-
children: ( editorRoles
171-
? Object.values( editorRoles )
172-
: [
173-
__( 'Role Manager', i18n ),
174-
__( 'Administrator', i18n ),
175-
__( 'Editor', i18n ),
176-
__( 'Author', i18n ),
177-
__( 'Contributor', i18n ),
178-
__( 'Subscriber', i18n ),
179-
]
180-
),
170+
children: Object.values( editorRoles || {} ),
181171
},
182172
],
183173
},
@@ -189,17 +179,7 @@ const SEARCH_TREE = [
189179
id: 'custom-fields-settings',
190180
children: [
191181
__( 'Custom Fields', i18n ),
192-
...( editorRoles
193-
? Object.values( editorRoles )
194-
: [
195-
__( 'Role Manager', i18n ),
196-
__( 'Administrator', i18n ),
197-
__( 'Editor', i18n ),
198-
__( 'Author', i18n ),
199-
__( 'Contributor', i18n ),
200-
__( 'Subscriber', i18n ),
201-
]
202-
),
182+
...Object.values( editorRoles || {} ),
203183
],
204184
},
205185
],

0 commit comments

Comments
 (0)