Enforce a redirection on the login page if the account is logued in

Use the APP_URL variable to define the base url
Bump the package number
This commit is contained in:
Timothée Jaussoin 2021-07-29 16:58:18 +02:00
parent 0b8c4061fc
commit 98ddf1f065
3 changed files with 8 additions and 2 deletions

View file

@ -38,6 +38,10 @@ class AuthenticateController extends Controller
public function login(Request $request)
{
if (auth()->user()) {
return redirect()->route('account.panel');
}
return view('account.login');
}

View file

@ -13,6 +13,8 @@ class AppServiceProvider extends ServiceProvider
public function boot()
{
//
// Add following lines to force laravel to use APP_URL as root url for the app.
$strBaseURL = $this->app['url'];
$strBaseURL->forceRootUrl(config('app.url'));
}
}

View file

@ -8,7 +8,7 @@
#%define _datadir %{_datarootdir}
#%define _docdir %{_datadir}/doc
%define build_number 91
%define build_number 92
%define var_dir /var/opt/belledonne-communications
%define opt_dir /opt/belledonne-communications/share/flexisip-account-manager