]> git.mxchange.org Git - friendica.git/blobdiff - src/Model/Post/Delayed.php
Merge pull request #12221 from MrPetovan/bug/warnings
[friendica.git] / src / Model / Post / Delayed.php
index 24b9989a4b2fca4db4a515e77ec51b048dc3dbd0..3f96af6984bff4092ec360be0418c31ad09d435e 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /**
- * @copyright Copyright (C) 2010-2021, the Friendica project
+ * @copyright Copyright (C) 2010-2022, the Friendica project
  *
  * @license GNU AGPL version 3 or any later version
  *
@@ -33,8 +33,21 @@ use Friendica\Util\DateTimeFormat;
 
 class Delayed
 {
+       /**
+        * The content of the post is posted as is. Connector settings are using the default settings.
+        * This is used for automated scheduled posts via feeds or from the API.
+        */
        const PREPARED = 0;
+       /**
+        * The content is posted like a manual post. Means some processing of body will be done.
+        * Also it is posted with default permissions and default connector settings.
+        * This is used for mirrored connector posts.
+        */
        const UNPREPARED = 1;
+       /**
+        * Like PREPARED, but additionally the connector settings can differ.
+        * This is used when manually publishing scheduled posts.
+        */
        const PREPARED_NO_HOOK = 2;
 
        /**
@@ -67,7 +80,7 @@ class Delayed
 
                Logger::notice('Adding post for delayed publishing', ['uid' => $item['uid'], 'delayed' => $delayed, 'uri' => $uri]);
 
-               $wid = Worker::add(['priority' => PRIORITY_HIGH, 'delayed' => $delayed], 'DelayedPublish', $item, $notify, $taglist, $attachments, $preparation_mode, $uri);
+               $wid = Worker::add(['priority' => Worker::PRIORITY_HIGH, 'delayed' => $delayed], 'DelayedPublish', $item, $notify, $taglist, $attachments, $preparation_mode, $uri);
                if (!$wid) {
                        return 0;
                }