]> git.mxchange.org Git - friendica.git/commitdiff
Replace && by AND in SQL queries
authorHypolite Petovan <mrpetovan@gmail.com>
Thu, 8 Jun 2017 02:01:14 +0000 (22:01 -0400)
committerHypolite Petovan <mrpetovan@gmail.com>
Thu, 8 Jun 2017 02:01:14 +0000 (22:01 -0400)
include/queue.php
update.php

index a92f2b207492b4fcfa7bcf9157e6d96b99c251cb..5e73922f9a948daf9b939397061e8856a17f7333 100644 (file)
@@ -44,7 +44,7 @@ function queue_run(&$argv, &$argc){
                // For the first 12 hours we'll try to deliver every 15 minutes
                // After that, we'll only attempt delivery once per hour.
 
-               $r = q("SELECT `id` FROM `queue` WHERE ((`created` > UTC_TIMESTAMP() - INTERVAL 12 HOUR && `last` < UTC_TIMESTAMP() - INTERVAL 15 MINUTE) OR (`last` < UTC_TIMESTAMP() - INTERVAL 1 HOUR)) ORDER BY `cid`, `created`");
+               $r = q("SELECT `id` FROM `queue` WHERE ((`created` > UTC_TIMESTAMP() - INTERVAL 12 HOUR AND `last` < UTC_TIMESTAMP() - INTERVAL 15 MINUTE) OR (`last` < UTC_TIMESTAMP() - INTERVAL 1 HOUR)) ORDER BY `cid`, `created`");
 
                call_hooks('queue_predeliver', $a, $r);
 
index 83f3dada5357eaa74a8b89a1b8b09756c4734395..aaa7aa0b9e62161b0cb74f7010d122a60a1d5487 100644 (file)
@@ -356,7 +356,7 @@ function update_1035() {
 
 function update_1036() {
 
-       $r = dbq("SELECT * FROM `contact` WHERE `network` = 'dfrn' && `photo` LIKE '%include/photo%' ");
+       $r = dbq("SELECT * FROM `contact` WHERE `network` = 'dfrn' AND `photo` LIKE '%include/photo%' ");
        if (dbm::is_result($r)) {
                foreach ($r as $rr) {
                        q("UPDATE `contact` SET `photo` = '%s', `thumb` = '%s', `micro` = '%s' WHERE `id` = %d",