File tree Expand file tree Collapse file tree 1 file changed +10
-5
lines changed
dotcom-rendering/src/server Expand file tree Collapse file tree 1 file changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -81,13 +81,18 @@ export const htmlPageTemplate = (props: WebProps | AppProps): string => {
8181 } = props ;
8282
8383 const doNotIndex = ( ) : boolean => {
84- const isDevelopment = process . env . GU_STAGE !== 'PROD' ;
84+ if ( process . env . GU_STAGE !== 'PROD' ) return true ;
85+ if ( ! canonicalUrl ) return false ;
8586
86- const hasNoIndexPattern = Boolean (
87- canonicalUrl ?. includes ( 'tracking/commissioningdesk' ) ,
88- ) ;
87+ const isAllowListed = [
88+ 'tracking/commissioningdesk/the-filter' ,
89+ 'tracking/commissioningdesk/filter-us' ,
90+ ] . some ( ( allowed ) => canonicalUrl . includes ( allowed ) ) ;
8991
90- return isDevelopment || hasNoIndexPattern ;
92+ return (
93+ canonicalUrl . includes ( 'tracking/commissioningdesk' ) &&
94+ ! isAllowListed
95+ ) ;
9196 } ;
9297
9398 /**
You can’t perform that action at this time.
0 commit comments