This commit is contained in:
Shish 2023-02-12 12:26:55 +00:00
parent 817a2ff2f4
commit 03cf09937b
5 changed files with 17 additions and 14 deletions

View file

@ -51,7 +51,7 @@
"bower-asset/jquery-timeago" : "^1.5", "bower-asset/jquery-timeago" : "^1.5",
"bower-asset/js-cookie" : "^2.1", "bower-asset/js-cookie" : "^2.1",
"psr/simple-cache" : "^1.0", "psr/simple-cache" : "^1.0",
"sabre/cache" : "^2.0", "sabre/cache" : "^2.0.1",
"naroga/redis-cache": "dev-master" "naroga/redis-cache": "dev-master"
}, },

21
composer.lock generated
View file

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "d010608b1d82774bd3444615496f254f", "content-hash": "8c41348f24ac414b8a2f9efafc3d30b1",
"packages": [ "packages": [
{ {
"name": "bower-asset/jquery", "name": "bower-asset/jquery",
@ -449,16 +449,16 @@
}, },
{ {
"name": "sabre/cache", "name": "sabre/cache",
"version": "2.0.0", "version": "2.0.1",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/sabre-io/cache.git", "url": "https://github.com/sabre-io/cache.git",
"reference": "8120da1320b4e0288fa2ff49cebb1a8221641faa" "reference": "a843741b85025d8674bf4713121cae60172e6f86"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/sabre-io/cache/zipball/8120da1320b4e0288fa2ff49cebb1a8221641faa", "url": "https://api.github.com/repos/sabre-io/cache/zipball/a843741b85025d8674bf4713121cae60172e6f86",
"reference": "8120da1320b4e0288fa2ff49cebb1a8221641faa", "reference": "a843741b85025d8674bf4713121cae60172e6f86",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
@ -469,9 +469,12 @@
"psr/simple-cache-implementation": "~1.0" "psr/simple-cache-implementation": "~1.0"
}, },
"require-dev": { "require-dev": {
"friendsofphp/php-cs-fixer": "^3.10.0", "friendsofphp/php-cs-fixer": "^3.14.0",
"phpstan/phpstan": "^1.8", "phpstan/extension-installer": "^1.2",
"phpunit/phpunit": "^9.0" "phpstan/phpstan": "^1.9",
"phpstan/phpstan-phpunit": "^1.3",
"phpstan/phpstan-strict-rules": "^1.4",
"phpunit/phpunit": "^9.6"
}, },
"type": "library", "type": "library",
"autoload": { "autoload": {
@ -508,7 +511,7 @@
"issues": "https://github.com/sabre-io/cache/issues", "issues": "https://github.com/sabre-io/cache/issues",
"source": "https://github.com/fruux/sabre-skel" "source": "https://github.com/fruux/sabre-skel"
}, },
"time": "2022-08-23T08:05:52+00:00" "time": "2023-02-09T23:47:10+00:00"
}, },
{ {
"name": "shish/eventtracer-php", "name": "shish/eventtracer-php",

View file

@ -159,7 +159,7 @@ class Image
* @param String[] $tags * @param String[] $tags
* @return Image[] * @return Image[]
*/ */
#[Query(name: "posts", type: "[Post]", args: ["tags" => "[string]"])] #[Query(name: "posts", type: "[Post!]!", args: ["tags" => "[string!]"])]
public static function find_images(?int $start = 0, ?int $limit = null, array $tags=[]): array public static function find_images(?int $start = 0, ?int $limit = null, array $tags=[]): array
{ {
$result = self::find_images_internal($start, $limit, $tags); $result = self::find_images_internal($start, $limit, $tags);
@ -466,7 +466,7 @@ class Image
* *
* @return String[] * @return String[]
*/ */
#[Field(name: "tags", type: "[string]")] #[Field(name: "tags", type: "[string!]!")]
public function get_tag_array(): array public function get_tag_array(): array
{ {
global $database; global $database;

View file

@ -50,7 +50,7 @@ class AutoComplete extends Extension
return []; return [];
} }
# temporary workaround for https://github.com/sabre-io/cache/issues/48 # memcache keys can't contain spaces
$cache_key = str_replace(' ', '+', "autocomplete-$search"); $cache_key = str_replace(' ', '+', "autocomplete-$search");
$limitSQL = ""; $limitSQL = "";
$search = str_replace('_', '\_', $search); $search = str_replace('_', '\_', $search);

View file

@ -105,7 +105,7 @@ class Rule34 extends Extension
{ {
global $database, $page, $user; global $database, $page, $user;
# Database might not be connected at this point... # Database might not be connected at this point...
#$database->set_timeout(DATABASE_TIMEOUT+15000); // deleting users can take a while #$database->set_timeout(DATABASE_TIMEOUT+15000); // deleting users can take a while
if (function_exists("sd_notify_watchdog")) { if (function_exists("sd_notify_watchdog")) {