summaryrefslogtreecommitdiff
path: root/includes/pages/admin_import.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/pages/admin_import.php')
-rw-r--r--includes/pages/admin_import.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/includes/pages/admin_import.php b/includes/pages/admin_import.php
index 786ea08b..0ed2bea9 100644
--- a/includes/pages/admin_import.php
+++ b/includes/pages/admin_import.php
@@ -162,7 +162,9 @@ function admin_import() {
list($rooms_new, $rooms_deleted) = prepare_rooms($import_file);
foreach ($rooms_new as $room) {
- sql_query("INSERT INTO `Room` SET `Name`='" . sql_escape($room) . "', `FromPentabarf`='Y', `Show`='Y'");
+ $result = Room_create($name, true, true);
+ if ($result === false)
+ engelsystem_error('Unable to create room.');
$rooms_import[trim($room)] = sql_id();
}
foreach ($rooms_deleted as $room)