mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-11 13:02:15 +09:00
Allow getTimeGap() to return null if zdate() returns null
This commit is contained in:
parent
bb7954ca10
commit
08b272f172
1 changed files with 2 additions and 2 deletions
|
|
@ -734,9 +734,9 @@ function getDisplayDateTime(?int $timestamp = null, string $format = 'YmdHis'):
|
||||||
*
|
*
|
||||||
* @param string $date Time value in format of YYYYMMDDHHIISS
|
* @param string $date Time value in format of YYYYMMDDHHIISS
|
||||||
* @param string $format If gap is within a day, returns this format.
|
* @param string $format If gap is within a day, returns this format.
|
||||||
* @return string
|
* @return ?string
|
||||||
*/
|
*/
|
||||||
function getTimeGap($date, $format = 'Y.m.d'): string
|
function getTimeGap($date, $format = 'Y.m.d'): ?string
|
||||||
{
|
{
|
||||||
$timestamp = intval(ztime($date));
|
$timestamp = intval(ztime($date));
|
||||||
$gap = RX_TIME - $timestamp;
|
$gap = RX_TIME - $timestamp;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue