Browse Source
Updated new page modal to no longer disable page creation for page names 2 characters or less. Removed local regex check as the new page model already prepends the locale.
pull/7440/head
Brian Powell Jr
7 months ago
No known key found for this signature in database
GPG Key ID: 452080FC5442B172
1 changed files with
1 additions and
7 deletions
client/components/common/page-selector.vue
@ -103,8 +103,6 @@
import _ from 'lodash'
import gql from 'graphql-tag'
const localeSegmentRegex = /^[A-Z]{2}(-[A-Z]{2})?$/i
/* global siteLangs, siteConfig */
export default {
@ -190,11 +188,7 @@ export default {
return false
}
const firstSection = _ . head ( this . currentPath . split ( '/' ) )
if ( firstSection . length <= 1 ) {
return false
} else if ( localeSegmentRegex . test ( firstSection ) ) {
return false
} else if (
if (
_ . some ( [ 'login' , 'logout' , 'register' , 'verify' , 'favicons' , 'fonts' , 'img' , 'js' , 'svg' ] , p => {
return p === firstSection
} ) ) {