]> git.mxchange.org Git - friendica.git/commitdiff
Improved logging, avoid fatal error
authorMichael <heluecht@pirati.ca>
Wed, 30 Dec 2020 07:13:47 +0000 (07:13 +0000)
committerMichael <heluecht@pirati.ca>
Wed, 30 Dec 2020 07:13:47 +0000 (07:13 +0000)
mod/events.php
src/Model/Event.php

index d4a902c725bb5aefc6232660ffbf1d7e1f9c0bc6..bf813f68372535e6f2d7aad83c11ce378ebc5e0f 100644 (file)
@@ -30,6 +30,7 @@ use Friendica\Core\Theme;
 use Friendica\Core\Worker;
 use Friendica\Database\DBA;
 use Friendica\DI;
+use Friendica\Model\Contact;
 use Friendica\Model\Event;
 use Friendica\Model\Item;
 use Friendica\Model\User;
@@ -129,7 +130,7 @@ function events_post(App $a)
        ];
 
        $action = ($event_id == '') ? 'new' : 'event/' . $event_id;
-       $onerror_path = 'events/' . $action . '?' . http_build_query($params, null, null, PHP_QUERY_RFC3986);
+       $onerror_path = 'events/' . $action . '?' . http_build_query($params, '', '&', PHP_QUERY_RFC3986);
 
        if (strcmp($finish, $start) < 0 && !$nofinish) {
                notice(DI::l10n()->t('Event can not end before it has started.'));
index 2b4932b4f7b5c6691c11570fbc32b883d7247484..995941edd0b568740c7d4102e7f5297b39ac5870 100644 (file)
@@ -292,7 +292,7 @@ class Event
 
                $contact = DBA::selectFirst('contact', [], $conditions);
                if (!DBA::isResult($contact)) {
-                       Logger::warning('Contact not found', ['condition' => $conditions]);
+                       Logger::warning('Contact not found', ['condition' => $conditions, 'cakkstack' => System::callstack(20)]);
                }
 
                // Existing event being modified.