Skip to content

Commit

Permalink
ENH Avoid using deprecated API (#207)
Browse files Browse the repository at this point in the history
  • Loading branch information
GuySartorelli authored Oct 21, 2024
1 parent daf11b8 commit 8fe9f6c
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/Publisher.php
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,11 @@ protected function generatePHPCacheFile($response)
*/
protected function generateHTMLCacheRedirection($destination)
{
return SSViewer::execute_template(
'SilverStripe\\StaticPublishQueue\\HTMLRedirection',
ArrayData::create([
'URL' => DBField::create_field('Varchar', $destination),
])
);
$viewer = SSViewer::create('SilverStripe\\StaticPublishQueue\\HTMLRedirection');
$viewer->setRewriteHashLinks(false);
$viewer->includeRequirements(false);
return $viewer->process(ArrayData::create([
'URL' => DBField::create_field('Varchar', $destination),
]));
}
}

0 comments on commit 8fe9f6c

Please sign in to comment.