]> git.mxchange.org Git - friendica-addons.git/commitdiff
statistics: Bugfix for query.
authorMichael Vogel <icarus@dabo.de>
Mon, 3 Feb 2014 21:39:02 +0000 (22:39 +0100)
committerMichael Vogel <icarus@dabo.de>
Mon, 3 Feb 2014 21:39:02 +0000 (22:39 +0100)
statistics_json/statistics_json.php

index ffafb4000c1801b15029a12ec890b3d70b95393a..e29d7422890630c39a63036abc874b3ac49bb4b2 100644 (file)
@@ -46,7 +46,7 @@ function statistics_json_cron($a,$b) {
                $next = $last + (180 * 60);
                if($next > time()) {
                        logger('statistics_json_cron: calculation intervall not reached');
-                       return;
+       //              return;
                }
        }
         logger('statistics_json_cron: cron_start');
@@ -91,7 +91,7 @@ function statistics_json_cron($a,$b) {
                        set_config('statistics_json','active_users_monthly', $active_users_monthly);
        }
 
-       $posts = q("SELECT COUNT(*) AS local_posts FROM `item` WHERE `wall` left(body, 6) != '[share'");
+       $posts = q("SELECT COUNT(*) AS local_posts FROM `item` WHERE `wall` AND left(body, 6) != '[share'");
 
        if (!is_array($posts))
                $local_posts = -1;