mirror of
https://github.com/sbrl/Pepperminty-Wiki.git
synced 2024-11-22 04:23:01 +00:00
Fix crash when using the search bar in recent versions of php
This commit is contained in:
parent
440b4e9cda
commit
86206195b6
2 changed files with 3 additions and 2 deletions
|
@ -23,6 +23,7 @@ This file holds the changelog for Pepperminty Wiki. This is the master list of t
|
||||||
- Improved error handling on first run where the PHP Zip extension is not installed
|
- Improved error handling on first run where the PHP Zip extension is not installed
|
||||||
- Also extract to `._extra_data` if the directory is empty
|
- Also extract to `._extra_data` if the directory is empty
|
||||||
- Add `sidebar_show` to the settings GUI and the [configuration guide](https://starbeamrainbowlabs.com/labs/peppermint/peppermint-config-info.php)
|
- Add `sidebar_show` to the settings GUI and the [configuration guide](https://starbeamrainbowlabs.com/labs/peppermint/peppermint-config-info.php)
|
||||||
|
- Fix crash when using the search bar with PHP 8.0+
|
||||||
|
|
||||||
|
|
||||||
## v0.22
|
## v0.22
|
||||||
|
|
|
@ -533,7 +533,7 @@ class search
|
||||||
* Example I used when writing this: https://www.php.net/manual/en/function.strtok.php#94463
|
* Example I used when writing this: https://www.php.net/manual/en/function.strtok.php#94463
|
||||||
* @param string $query The query string to split.
|
* @param string $query The query string to split.
|
||||||
*/
|
*/
|
||||||
public function stas_split($query) {
|
public static function stas_split($query) {
|
||||||
$query = self::$literator->transliterate($query);
|
$query = self::$literator->transliterate($query);
|
||||||
|
|
||||||
$terms = [];
|
$terms = [];
|
||||||
|
@ -561,7 +561,7 @@ class search
|
||||||
|
|
||||||
* @param string[] $tokens The array of query tokens to parse.
|
* @param string[] $tokens The array of query tokens to parse.
|
||||||
*/
|
*/
|
||||||
public function stas_parse($tokens) {
|
public static function stas_parse($tokens) {
|
||||||
global $settings;
|
global $settings;
|
||||||
|
|
||||||
/* Supported Syntax *
|
/* Supported Syntax *
|
||||||
|
|
Loading…
Reference in a new issue