]> git.mxchange.org Git - friendica.git/commitdiff
Issue 7285: Perform duplicate check for item URI also with AP
authorMichael <heluecht@pirati.ca>
Tue, 10 Sep 2019 04:59:12 +0000 (04:59 +0000)
committerMichael <heluecht@pirati.ca>
Tue, 10 Sep 2019 04:59:12 +0000 (04:59 +0000)
src/Model/Item.php

index 3a421e96c43508d8ad598cc1419ae4cf4707f1ea..22859f76b42c80b7dcc986e7ce3c2351baa6d317 100644 (file)
@@ -1398,9 +1398,9 @@ class Item extends BaseObject
                 * via OStatus (maybe Diasporsa as well)
                 */
                if (empty($item['network']) || in_array($item['network'], Protocol::FEDERATED)) {
-                       $condition = ["`uri` = ? AND `uid` = ? AND `network` IN (?, ?, ?)",
+                       $condition = ["`uri` = ? AND `uid` = ? AND `network` IN (?, ?, ?, ?)",
                                trim($item['uri']), $item['uid'],
-                               Protocol::DIASPORA, Protocol::DFRN, Protocol::OSTATUS];
+                               Protocol::ACTIVITYPUB, Protocol::DIASPORA, Protocol::DFRN, Protocol::OSTATUS];
                        $existing = self::selectFirst(['id', 'network'], $condition);
                        if (DBA::isResult($existing)) {
                                // We only log the entries with a different user id than 0. Otherwise we would have too many false positives