summaryrefslogtreecommitdiffstats
path: root/modules-available/locationinfo/api.inc.php
diff options
context:
space:
mode:
authorJannik Schönartz2017-03-09 12:09:34 +0100
committerJannik Schönartz2017-03-09 12:09:34 +0100
commit86aa9c8d37de29bc4a46881fb70b72619c3cc390 (patch)
tree848b58d9cee3bab2e11f38712ca3c3d5207c866b /modules-available/locationinfo/api.inc.php
parentAPI: Reworked getRoomInfo with isset and added overlay if coords = true (diff)
downloadslx-admin-86aa9c8d37de29bc4a46881fb70b72619c3cc390.tar.gz
slx-admin-86aa9c8d37de29bc4a46881fb70b72619c3cc390.tar.xz
slx-admin-86aa9c8d37de29bc4a46881fb70b72619c3cc390.zip
API: Send an empty array if the overlay is null
Diffstat (limited to 'modules-available/locationinfo/api.inc.php')
-rw-r--r--modules-available/locationinfo/api.inc.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/modules-available/locationinfo/api.inc.php b/modules-available/locationinfo/api.inc.php
index 575b04f4..3a6618d8 100644
--- a/modules-available/locationinfo/api.inc.php
+++ b/modules-available/locationinfo/api.inc.php
@@ -327,6 +327,9 @@ function getRoomInfo($idList, $coords) {
$pc['x'] = $position['gridCol'];
$pc['y'] = $position['gridRow'];
$pc['overlay'] = $position['overlays'];
+ if ($pc['overlay'] == null) {
+ $pc['overlay'] = array();
+ }
}
$pc['pcState'] = LocationInfo::getPcState($dbdata);