]> git.mxchange.org Git - friendica.git/commitdiff
Fix issues in changed files
authorHypolite Petovan <mrpetovan@gmail.com>
Tue, 16 Jan 2018 00:27:48 +0000 (19:27 -0500)
committerHypolite Petovan <mrpetovan@gmail.com>
Wed, 17 Jan 2018 05:17:58 +0000 (00:17 -0500)
- Initializes $return in Process::insert
- Update the type hint of dba::fetch
- Remove unused $a parameter in worker_init()
- Fix uses

include/dba.php
mod/worker.php
scripts/worker.php
src/Model/Process.php

index 6471d364514884cf98a77f970676b10583715093..b1b689fdf77def7090d8b5bd54059e1fc9c1cd24 100644 (file)
@@ -659,7 +659,7 @@ class dba {
        /**
         * @brief Fetch a single row
         *
-        * @param PDOStatement|mysqli_result|mysqli_stmt $stmt statement object
+        * @param mixed $stmt statement object
         * @return array current row
         */
        public static function fetch($stmt) {
index 056416e799d4022d2e203d709fe2643ddf915564..1bd58807895fab1ae5c6782964925ab98151774d 100644 (file)
@@ -4,11 +4,10 @@
  * @brief Module for running the worker as frontend process
  */
 
-use Friendica\Core\Worker;
 use Friendica\Core\Config;
-use Friendica\Core\PConfig;
+use Friendica\Core\Worker;
 
-function worker_init($a){
+function worker_init(){
 
        if (!Config::get("system", "frontend_worker")) {
                return;
index d69b089aecb0b904616e5886a49c6ef2b601d0d8..ccf24b7b43dd005421f9410e24b592280e92a9f7 100755 (executable)
@@ -6,8 +6,8 @@
  */
 
 use Friendica\App;
-use Friendica\Core\Worker;
 use Friendica\Core\Config;
+use Friendica\Core\Worker;
 
 // Ensure that worker.php is executed from the base path of the installation
 if (!file_exists("boot.php") && (sizeof($_SERVER["argv"]) != 0)) {
index 6b2d2fb64b66bc2824c6bc2a4450e37fa0b4e44f..fbc844c8d2d0fc4985ce1089714e2a9de1dc4184 100644 (file)
@@ -23,6 +23,8 @@ class Process extends BaseObject
         */
        public static function insert($command, $pid = null)
        {
+               $return = true;
+
                dba::transaction();
 
                if (!dba::exists('process', ['pid' => getmypid()])) {