Skip to content

Commit d1befee

Browse files
authored
Merge pull request #108 from rosteleset/codex/allow-empty-flat-floor
Allow empty flat floor when modifying flats
2 parents a50bcf9 + 05e845c commit d1befee

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

server/backends/households/internal/internal.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -916,6 +916,10 @@ function modifyFlat($flatId, $params) {
916916
$params["password"] = null;
917917
}
918918

919+
if (array_key_exists("floor", $params) && !is_array($params["floor"]) && trim((string)$params["floor"]) === "") {
920+
$params["floor"] = 0;
921+
}
922+
919923
if (array_key_exists("floor", $params) && !checkInt($params["floor"])) {
920924
setLastError("invalidParams");
921925
return false;

0 commit comments

Comments
 (0)