Comments Updated

This commit is contained in:
devansh bawari 2021-06-09 12:19:11 +05:30
parent dba2b7989d
commit 85cf69b27a
1 changed files with 5 additions and 3 deletions

View File

@ -314,13 +314,15 @@ class Core
}
/**
* Get locale code from request.
* Get locale code from request. Here if you want to use admin locale,
* you can pass it as an argument.
*
* @param string $localeKey optional
* @return string
*/
public function getRequestedLocaleCode($localeCode = 'locale'): string
public function getRequestedLocaleCode($localeKey = 'locale'): string
{
return request()->get($localeCode) ?: app()->getLocale();
return request()->get($localeKey) ?: app()->getLocale();
}
/**