Skip to content

Commit

Permalink
ENH Stop using Controller::has_curr()
Browse files Browse the repository at this point in the history
  • Loading branch information
emteknetnz committed Feb 13, 2025
1 parent 0b5e35a commit 5bb6e6f
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/Extension/Traits/FluentObjectTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,7 @@ protected function updateFluentCMSFields(FieldList $fields)

// Augment Localisation tab with clickable locale links to allow easy navigation between model localisations
if ($owner->hasExtension(CMSEditLinkExtension::class)) {
$controller = Controller::has_curr() ? Controller::curr() : null;
$request = $controller?->getRequest();
$request = Controller::curr()?->getRequest();

// Pass getVars separately so we can process them later
$params = $request?->getVars() ?? [];
Expand Down

0 comments on commit 5bb6e6f

Please sign in to comment.