check for existence of mx data
This commit is contained in:
parent
f43aa884d5
commit
0680b75cc5
@ -578,12 +578,12 @@ class MapManager implements CallbackListener {
|
||||
/**
|
||||
* Get's a Map by it's Mania-Exchange Id
|
||||
*
|
||||
* @param $mxId
|
||||
* @param int $mxId
|
||||
* @return Map
|
||||
*/
|
||||
public function getMapByMxId($mxId) {
|
||||
foreach ($this->maps as $map) {
|
||||
if ($map->mx->id == $mxId) {
|
||||
if ($map->mx && $map->mx->id == $mxId) {
|
||||
return $map;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user