diff --git a/core/dbengine.php b/core/dbengine.php index cd3f4bb4..638da437 100644 --- a/core/dbengine.php +++ b/core/dbengine.php @@ -217,7 +217,6 @@ class SQLite extends DBEngine $data = str_replace(SCORE::BOOL_Y, "'$this->BOOL_Y'", $data); $data = str_replace(SCORE::BOOL_N, "'$this->BOOL_N'", $data); $data = str_replace(SCORE::BOOL, "CHAR(1)", $data); - $data = str_replace("DEFAULT FALSE", "DEFAULT 0", $data); return $data; } diff --git a/ext/private_image/main.php b/ext/private_image/main.php index a22b9420..316d079e 100644 --- a/ext/private_image/main.php +++ b/ext/private_image/main.php @@ -133,13 +133,13 @@ class PrivateImage extends Extension if ($show_private) { $event->add_querylet( new Querylet( - "private = :false OR owner_id = :private_owner_id", - ["private_owner_id"=>$user->id, "false"=>false] + "private != :true OR owner_id = :private_owner_id", + ["private_owner_id"=>$user->id, "true"=>true] ) ); } else { $event->add_querylet( - new Querylet("private = :false", ["false"=>false]) + new Querylet("private != :true", ["true"=>true]) ); } } @@ -153,8 +153,8 @@ class PrivateImage extends Extension $query = ""; switch ($matches[1]) { case "no": - $query .= "private = :false"; - $params["false"] = false; + $query .= "private != :true"; + $params["true"] = true; break; case "yes": $query .= "private = :true"; @@ -168,8 +168,8 @@ class PrivateImage extends Extension } break; case "any": - $query .= "private = :false OR owner_id = :private_owner_id"; - $params["false"] = false; + $query .= "private != :true OR owner_id = :private_owner_id"; + $params["true"] = true; $params["private_owner_id"] = $user->id; break; } diff --git a/ext/trash/main.php b/ext/trash/main.php index c80eb7da..91dcf985 100644 --- a/ext/trash/main.php +++ b/ext/trash/main.php @@ -97,7 +97,7 @@ class Trash extends Extension $matches = []; if (is_null($event->term) && $this->no_trash_query($event->context)) { - $event->add_querylet(new Querylet("trash = :false", ["false"=>false])); + $event->add_querylet(new Querylet("trash != :true", ["true"=>true])); } if (is_null($event->term)) {