Skip to content

Commit

Permalink
FIX Warning: Undefined array key "Locale" (silverstripe#1365)
Browse files Browse the repository at this point in the history
  • Loading branch information
lekoala authored and GuySartorelli committed Sep 26, 2022
1 parent 7eb1f3f commit eab5986
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion code/CMSProfileController.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public function save($data, $form)

$response = parent::save($data, $form);

if ($origLocale != $data['Locale']) {
if (isset($data['Locale']) && $origLocale != $data['Locale']) {
$response->addHeader('X-Reload', true);
$response->addHeader('X-ControllerURL', $this->Link());
}
Expand Down

0 comments on commit eab5986

Please sign in to comment.