1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-04-12 03:42:05 +02:00

Merge branch '3.2.x'

This commit is contained in:
Marc Alexander 2017-12-27 19:14:03 +01:00
commit a4a57b5860
No known key found for this signature in database
GPG Key ID: 50E0D2423696F995

View File

@ -60,6 +60,12 @@ class datetime extends \DateTime
public function format($format = '', $force_absolute = false)
{
$format = $format ? $format : $this->user->date_format;
if (substr($this->user->lang_name, 0,2) != 'en')
{
$format = preg_replace('/([^\\\])S/','$1', $format);
}
$format = self::format_cache($format, $this->user);
$relative = ($format['is_short'] && !$force_absolute);
$now = new self($this->user, 'now', $this->user->timezone);