Skip to content

Commit

Permalink
Added a default locale setting during application initialization.
Browse files Browse the repository at this point in the history
Signed-off-by: Andrey Novakovskiy <[email protected]>
  • Loading branch information
Novakovskiy committed May 29, 2020
1 parent 6d019e5 commit 2717873
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions system/CodeIgniter.php
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,9 @@ public function __construct($config)
*/
public function initialize()
{
// Set default locale on the server
locale_set_default($this->config->defaultLocale ?? 'en');

// Set default timezone on the server
date_default_timezone_set($this->config->appTimezone ?? 'UTC');

Expand Down

0 comments on commit 2717873

Please sign in to comment.