@@ -298,7 +298,7 @@ module.exports = {
298298  async  created ( page )  { 
299299    WIKI . logger . info ( `(STORAGE/GIT) Committing new file [${ page . localeCode }  ] ${ page . path }  ...` ) 
300300    let  fileName  =  `${ page . path }  .${ pageHelper . getFileExtension ( page . contentType ) }  ` 
301-     if  ( WIKI . config . lang . namespacing  &&  WIKI . config . lang . code  !==  page . localeCode )  { 
301+     if  ( this . config . alwaysNamespace   ||   ( WIKI . config . lang . namespacing  &&  WIKI . config . lang . code  !==  page . localeCode ) )  { 
302302      fileName  =  `${ page . localeCode }  /${ fileName }  ` 
303303    } 
304304    const  filePath  =  path . join ( this . repoPath ,  fileName ) 
@@ -320,7 +320,7 @@ module.exports = {
320320  async  updated ( page )  { 
321321    WIKI . logger . info ( `(STORAGE/GIT) Committing updated file [${ page . localeCode }  ] ${ page . path }  ...` ) 
322322    let  fileName  =  `${ page . path }  .${ pageHelper . getFileExtension ( page . contentType ) }  ` 
323-     if  ( WIKI . config . lang . namespacing  &&  WIKI . config . lang . code  !==  page . localeCode )  { 
323+     if  ( this . config . alwaysNamespace   ||   ( WIKI . config . lang . namespacing  &&  WIKI . config . lang . code  !==  page . localeCode ) )  { 
324324      fileName  =  `${ page . localeCode }  /${ fileName }  ` 
325325    } 
326326    const  filePath  =  path . join ( this . repoPath ,  fileName ) 
@@ -342,7 +342,7 @@ module.exports = {
342342  async  deleted ( page )  { 
343343    WIKI . logger . info ( `(STORAGE/GIT) Committing removed file [${ page . localeCode }  ] ${ page . path }  ...` ) 
344344    let  fileName  =  `${ page . path }  .${ pageHelper . getFileExtension ( page . contentType ) }  ` 
345-     if  ( WIKI . config . lang . namespacing  &&  WIKI . config . lang . code  !==  page . localeCode )  { 
345+     if  ( this . config . alwaysNamespace   ||   ( WIKI . config . lang . namespacing  &&  WIKI . config . lang . code  !==  page . localeCode ) )  { 
346346      fileName  =  `${ page . localeCode }  /${ fileName }  ` 
347347    } 
348348
@@ -364,11 +364,11 @@ module.exports = {
364364    let  sourceFileName  =  `${ page . path }  .${ pageHelper . getFileExtension ( page . contentType ) }  ` 
365365    let  destinationFileName  =  `${ page . destinationPath }  .${ pageHelper . getFileExtension ( page . contentType ) }  ` 
366366
367-     if  ( WIKI . config . lang . namespacing )  { 
368-       if  ( WIKI . config . lang . code  !==  page . localeCode )  { 
367+     if  ( this . config . alwaysNamespace   ||   WIKI . config . lang . namespacing )  { 
368+       if  ( this . config . alwaysNamespace   ||   WIKI . config . lang . code  !==  page . localeCode )  { 
369369        sourceFileName  =  `${ page . localeCode }  /${ sourceFileName }  ` 
370370      } 
371-       if  ( WIKI . config . lang . code  !==  page . destinationLocaleCode )  { 
371+       if  ( this . config . alwaysNamespace   ||   WIKI . config . lang . code  !==  page . destinationLocaleCode )  { 
372372        destinationFileName  =  `${ page . destinationLocaleCode }  /${ destinationFileName }  ` 
373373      } 
374374    } 
@@ -483,7 +483,7 @@ module.exports = {
483483          page . tags  =  await  pageObject . $relatedQuery ( 'tags' ) 
484484
485485          let  fileName  =  `${ page . path }  .${ pageHelper . getFileExtension ( page . contentType ) }  ` 
486-           if  ( WIKI . config . lang . namespacing  &&  WIKI . config . lang . code  !==  page . localeCode )  { 
486+           if  ( this . config . alwaysNamespace   ||   ( WIKI . config . lang . namespacing  &&  WIKI . config . lang . code  !==  page . localeCode ) )  { 
487487            fileName  =  `${ page . localeCode }  /${ fileName }  ` 
488488          } 
489489          WIKI . logger . info ( `(STORAGE/GIT) Adding page ${ fileName }  ...` ) 
0 commit comments