while (true) {
  if ($current === $requested) {
     break;
  }
  if (! in_array($requested, $available)) {
     break;
  }
  session()->put('locale', $requested);
  break;
}
By Ed, 2020-08-05 15:26:32