diff options
| author | Andrew Dolgov <fox@fakecake.org> | 2024-12-10 05:22:37 +0000 |
|---|---|---|
| committer | Andrew Dolgov <fox@fakecake.org> | 2024-12-10 05:22:37 +0000 |
| commit | 0ef2dd7175248e1116a867e0a86579d9f6ca16eb (patch) | |
| tree | 452fc6e3391544b209ea075d587935e7ab42e714 /vendor/thecodingmachine/safe/deprecated/datetime.php | |
| parent | f15db7b9610467aa29f6441361fdc4e6c90deaa1 (diff) | |
| parent | 3860435cba19cf2cd9c86dcc5d8938198c6b6736 (diff) | |
Merge branch 'feature/alpine_3.21-and-php_8.4' into 'master'
Bump to Alpine 3.21 and PHP 8.4, raise the minimum to PHP 8.2
See merge request tt-rss/tt-rss!85
Diffstat (limited to 'vendor/thecodingmachine/safe/deprecated/datetime.php')
| -rw-r--r-- | vendor/thecodingmachine/safe/deprecated/datetime.php | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/vendor/thecodingmachine/safe/deprecated/datetime.php b/vendor/thecodingmachine/safe/deprecated/datetime.php deleted file mode 100644 index 1bcb32275..000000000 --- a/vendor/thecodingmachine/safe/deprecated/datetime.php +++ /dev/null @@ -1,36 +0,0 @@ -<?php - -namespace Safe; - -use Safe\Exceptions\DatetimeException; - -/** - * Identical to the date function except that - * the time returned is Greenwich Mean Time (GMT). - * - * @param string $format The format of the outputted date string. See the formatting - * options for the date function. - * @param int $timestamp The optional timestamp parameter is an - * integer Unix timestamp that defaults to the current - * local time if a timestamp is not given. In other - * words, it defaults to the value of time. - * @return string Returns a formatted date string. If a non-numeric value is used for - * timestamp, FALSE is returned and an - * E_WARNING level error is emitted. - * @throws DatetimeException - * @deprecated The Safe version of this function is no longer needed in PHP 8.0+ - * - */ -function gmdate(string $format, int $timestamp = null): string -{ - error_clear_last(); - if ($timestamp !== null) { - $result = \gmdate($format, $timestamp); - } else { - $result = \gmdate($format); - } - if ($result === false) { - throw DatetimeException::createFromPhpError(); - } - return $result; -} |