mirror of
https://github.com/standardebooks/web.git
synced 2025-07-16 11:26:37 -04:00
Code style tweaks to satisfy PHPStan
This commit is contained in:
parent
658db66c2b
commit
5c4617d759
6 changed files with 19 additions and 6 deletions
|
@ -1,6 +1,7 @@
|
|||
<?
|
||||
use function Safe\apcu_fetch;
|
||||
use function Safe\ksort;
|
||||
use function Safe\natsort;
|
||||
use function Safe\preg_replace;
|
||||
use function Safe\touch;
|
||||
use function Safe\unlink;
|
||||
|
@ -10,7 +11,7 @@ class Library{
|
|||
/**
|
||||
* @return array<Ebook>
|
||||
*/
|
||||
public static function FilterEbooks($query = null, $tags = [], $sort = null){
|
||||
public static function FilterEbooks(string $query = null, array $tags = [], string $sort = null){
|
||||
$ebooks = Library::GetEbooks();
|
||||
$matches = $ebooks;
|
||||
|
||||
|
@ -164,6 +165,10 @@ class Library{
|
|||
return $ebooks;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return array<Tag>
|
||||
*/
|
||||
public static function GetTags(): array{
|
||||
return apcu_fetch('tags');
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue