Compare commits

..

1 Commits

Author SHA1 Message Date
Guy Sartorelli
e279785301
ENH Improve type safety to support refactored template layer 2024-09-26 16:42:34 +12:00
2 changed files with 4 additions and 4 deletions

View File

@ -60,7 +60,7 @@ class ModelAsController extends Controller implements NestedController
Director::absoluteBaseURL(), Director::absoluteBaseURL(),
'dev/build', 'dev/build',
'?' . http_build_query([ '?' . http_build_query([
'BackURL' => isset($_GET['url']) ? $_GET['url'] : null, 'returnURL' => isset($_GET['url']) ? $_GET['url'] : null,
]) ])
)); ));
} }
@ -81,7 +81,7 @@ class ModelAsController extends Controller implements NestedController
// If the database has not yet been created, redirect to the build page. // If the database has not yet been created, redirect to the build page.
if (!DB::is_active() || !ClassInfo::hasTable('SiteTree')) { if (!DB::is_active() || !ClassInfo::hasTable('SiteTree')) {
$this->getResponse()->redirect(Controller::join_links(Director::absoluteBaseURL(), 'dev/build?BackURL=' . (isset($_GET['url']) ? urlencode($_GET['url']) : null))); $this->getResponse()->redirect(Controller::join_links(Director::absoluteBaseURL(), 'dev/build?returnURL=' . (isset($_GET['url']) ? urlencode($_GET['url']) : null)));
$this->popCurrent(); $this->popCurrent();
return $this->getResponse(); return $this->getResponse();

View File

@ -78,7 +78,7 @@ class RootURLController extends Controller implements Resettable
Director::absoluteBaseURL(), Director::absoluteBaseURL(),
'dev/build', 'dev/build',
'?' . http_build_query([ '?' . http_build_query([
'BackURL' => isset($_GET['url']) ? $_GET['url'] : null, 'returnURL' => isset($_GET['url']) ? $_GET['url'] : null,
]) ])
)); ));
} }
@ -91,7 +91,7 @@ class RootURLController extends Controller implements Resettable
if (!$this->getResponse()->isFinished()) { if (!$this->getResponse()->isFinished()) {
if (!DB::is_active() || !ClassInfo::hasTable('SiteTree')) { if (!DB::is_active() || !ClassInfo::hasTable('SiteTree')) {
$this->getResponse()->redirect(Director::absoluteBaseURL() . 'dev/build?BackURL=' . (isset($_GET['url']) ? urlencode($_GET['url']) : null)); $this->getResponse()->redirect(Director::absoluteBaseURL() . 'dev/build?returnURL=' . (isset($_GET['url']) ? urlencode($_GET['url']) : null));
return $this->getResponse(); return $this->getResponse();
} }