diff --git a/app/main/controller/api/map.php b/app/main/controller/api/map.php index 9138992c..9f8beaae 100644 --- a/app/main/controller/api/map.php +++ b/app/main/controller/api/map.php @@ -672,7 +672,7 @@ class Map extends Controller\AccessController { $cacheKey = 'user_data_' . $tempId . '_' . $requestSystemData->systemId; if( !$f3->exists($cacheKey) ){ foreach($mapIds as $mapId){ - $map = $activeCharacter->getMap($mapId); + $map = $activeCharacter->getMap( (int)$mapId); if( !is_null($map) ){ $return->mapUserData[] = $map->getUserData(); diff --git a/app/main/model/charactermodel.php b/app/main/model/charactermodel.php index 119dd172..c245a666 100644 --- a/app/main/model/charactermodel.php +++ b/app/main/model/charactermodel.php @@ -415,15 +415,15 @@ class CharacterModel extends BasicModel { /** * get mapModel by id and check if user has access - * @param int $mapId + * @param $mapId * @return MapModel|null */ - public function getMap(int $mapId){ + public function getMap($mapId){ /** * @var $map MapModel */ $map = self::getNew('MapModel'); - $map->getById( $mapId ); + $map->getById( (int)$mapId ); $returnMap = null; if($map->hasAccess($this)){