mirror of
https://github.com/Sarjuuk/aowow.git
synced 2025-11-29 15:58:16 +08:00
Misc/Errors
* Item/XML
- fixed setting typeId when lookup was item name
- fixed lookup by name with utf8-chars
* Items
- do not display page for invalid categories
* NPC
- fixed reputation display
* Quest
- broke infinite loop occuring when quest is in chain with itself
* Filters
- handle different sizes of cr, crs and crv passed
This commit is contained in:
@@ -229,7 +229,8 @@ class GenericPage
|
||||
case 0: // no params works always
|
||||
return true;
|
||||
case 1: // null is valid || value in a 1-dim-array || key for a n-dim-array
|
||||
return $this->category[0] === null || in_array($this->category[0], $this->validCats) || !empty($this->validCats[$this->category[0]]);
|
||||
$filtered = array_filter($this->validCats, function ($x) { return is_int($x); });
|
||||
return $this->category[0] === null || in_array($this->category[0], $filtered) || !empty($this->validCats[$this->category[0]]);
|
||||
case 2: // first param has to be a key. otherwise invalid
|
||||
if (!isset($this->validCats[$this->category[0]]))
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user