]> git.mxchange.org Git - friendica.git/commitdiff
Add type hint to Database::insert
authorHypolite Petovan <hypolite@mrpetovan.com>
Wed, 24 Jun 2020 13:36:34 +0000 (09:36 -0400)
committerHypolite Petovan <hypolite@mrpetovan.com>
Wed, 24 Jun 2020 13:36:34 +0000 (09:36 -0400)
- Will escalate warning to fatal error in https://github.com/friendica/friendica/issues/8474#issuecomment-646802016

src/Database/Database.php

index 806b2b86bbd73a48c3f4858fcb327544d742641e..897845ce0c8d6ba700c1a794d4149c99f0e1263c 100644 (file)
@@ -979,7 +979,7 @@ class Database
         * @return boolean was the insert successful?
         * @throws \Exception
         */
-       public function insert($table, $param, $on_duplicate_update = false)
+       public function insert($table, array $param, bool $on_duplicate_update = false)
        {
                if (empty($table) || empty($param)) {
                        $this->logger->info('Table and fields have to be set');