mirror of
https://github.com/friendica/friendica
synced 2025-04-26 19:50:10 +00:00
Move NULL_DATE from boot.php to DBA::NULL_DATETIME
- Add DBA::NULL_DATE constant
This commit is contained in:
parent
ca9cad3491
commit
e511790d62
19 changed files with 70 additions and 73 deletions
|
@ -257,10 +257,10 @@ class Event extends BaseObject
|
|||
|
||||
$event['created'] = DateTimeFormat::utc(defaults($arr, 'created' , 'now'));
|
||||
$event['edited'] = DateTimeFormat::utc(defaults($arr, 'edited' , 'now'));
|
||||
$event['start'] = DateTimeFormat::utc(defaults($arr, 'start' , NULL_DATE));
|
||||
$event['finish'] = DateTimeFormat::utc(defaults($arr, 'finish' , NULL_DATE));
|
||||
if ($event['finish'] < NULL_DATE) {
|
||||
$event['finish'] = NULL_DATE;
|
||||
$event['start'] = DateTimeFormat::utc(defaults($arr, 'start' , DBA::NULL_DATETIME));
|
||||
$event['finish'] = DateTimeFormat::utc(defaults($arr, 'finish' , DBA::NULL_DATETIME));
|
||||
if ($event['finish'] < DBA::NULL_DATETIME) {
|
||||
$event['finish'] = DBA::NULL_DATETIME;
|
||||
}
|
||||
$private = intval(defaults($arr, 'private', 0));
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue