]> git.mxchange.org Git - friendica.git/blobdiff - src/Worker/OnePoll.php
Don't add contacts when not needed
[friendica.git] / src / Worker / OnePoll.php
index 25402e3c3158d2890833656a71ca2efe16236171..107bd342467d435facdf6c73e31064e020cc8c2a 100644 (file)
@@ -4,8 +4,6 @@
  */
 namespace Friendica\Worker;
 
-use Friendica\BaseObject;
-use Friendica\Content\Text\BBCode;
 use Friendica\Core\Config;
 use Friendica\Core\Logger;
 use Friendica\Core\PConfig;
@@ -41,7 +39,7 @@ class OnePoll
                }
 
                if ($force) {
-                       Contact::updateFromProbe($contact_id, true);
+                       Contact::updateFromProbe($contact_id, '', true);
                }
 
                $contact = DBA::selectFirst('contact', [], ['id' => $contact_id]);
@@ -562,7 +560,7 @@ class OnePoll
                                        }
 
                                        // Decoding the header
-                                       $subject = imap_mime_header_decode($meta->subject);
+                                       $subject = imap_mime_header_decode($meta->subject ?? '');
                                        $datarray['title'] = "";
                                        foreach ($subject as $subpart) {
                                                if ($subpart->charset != "default") {