File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed
Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -222,10 +222,15 @@ class RewrittenData {
222222 return writeA ( `${ this . data . ref } --${ this . data . repo } --${ this . data . owner } .hlx.page${ value } ` , value ) ;
223223 }
224224 if ( type === 'sitemap' ) {
225- const paths = this . data . updated . map (
226- ( update ) => writeA ( `${ this . data . ref } --${ this . data . repo } --${ this . data . owner } .hlx.live${ update } ` , update ) ,
227- ) ;
228- return paths . join ( ', <br />' ) ;
225+ // when source: sitemap, we get arrays of paths
226+ if ( this . data . updated ) {
227+ const paths = this . data . updated . map (
228+ ( update ) => writeA ( `${ this . data . ref } --${ this . data . repo } --${ this . data . owner } .hlx.live${ update } ` , update ) ,
229+ ) ;
230+ return paths . join ( ', <br />' ) ;
231+ }
232+ // when route: sitemap, we only get a path
233+ return writeA ( `${ this . data . ref } --${ this . data . repo } --${ this . data . owner } .hlx.live${ this . data . path } ` , this . data . path ) ;
229234 }
230235 if ( type === 'status' ) {
231236 return writeA ( `${ ADMIN } /status/${ this . data . owner } /${ this . data . repo } /${ this . data . ref } ${ value } ` , value ) ;
You can’t perform that action at this time.
0 commit comments