[dss-commits] r8847 - dss/trunk/core
dss-commits at forum.digitalstrom.org
dss-commits at forum.digitalstrom.org
Thu Oct 15 12:09:23 CEST 2009
Author: pstaehlin
Date: 2009-10-15 12:09:23 +0200 (Thu, 15 Oct 2009)
New Revision: 8847
Modified:
dss/trunk/core/webserver.cpp
Log:
Removed unnecessary variable
Modified: dss/trunk/core/webserver.cpp
===================================================================
--- dss/trunk/core/webserver.cpp 2009-10-15 10:09:12 UTC (rev 8846)
+++ dss/trunk/core/webserver.cpp 2009-10-15 10:09:23 UTC (rev 8847)
@@ -1356,8 +1356,6 @@
_handled = true;
StructureManipulator manipulator(getDSS().getDS485Interface(), getDSS().getApartment());
if(endsWith(_method, "structure/zoneAddDevice")) {
- bool ok = true;
-
string devidStr = _parameter["devid"];
if(!devidStr.empty()) {
dsid_t devid = dsid::fromString(devidStr);
@@ -1378,11 +1376,11 @@
} catch(ItemNotFoundException&) {
return ResultToJSON(false, "Could not find zone");
}
- } catch(std::runtime_error&) {
- ok = false;
+ } catch(std::runtime_error& err) {
+ return ResultToJSON(false, err.what());
}
}
- return ResultToJSON(ok, "");
+ return ResultToJSON(true);
} else {
return ResultToJSON(false, "Need parameter devid");
}
More information about the dss-commits
mailing list