mirror of
https://github.com/beestat/app.git
synced 2025-06-05 14:48:34 -04:00
Improved some exception handling.
This commit is contained in:
parent
18429dd8ac
commit
c5c53c33b4
@ -219,10 +219,10 @@ class ecobee_sensor extends cora\crud {
|
|||||||
]
|
]
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
throw $e;
|
throw new cora\exception($e->getMessage(), $e->getCode(), $e->getReportable(), $e->getExtraInfo(), $e->getRollback());
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
throw $e;
|
throw new cora\exception($e->getMessage(), $e->getCode(), $e->getReportable(), $e->getExtraInfo(), $e->getRollback());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -182,10 +182,10 @@ class ecobee_thermostat extends cora\crud {
|
|||||||
]
|
]
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
throw $e;
|
throw new cora\exception($e->getMessage(), $e->getCode(), $e->getReportable(), $e->getExtraInfo(), $e->getRollback());
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
throw $e;
|
throw new cora\exception($e->getMessage(), $e->getCode(), $e->getReportable(), $e->getExtraInfo(), $e->getRollback());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -406,7 +406,7 @@ class runtime extends cora\api {
|
|||||||
strtotime('+1 hour', $end)
|
strtotime('+1 hour', $end)
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
throw $e;
|
throw new cora\exception($e->getMessage(), $e->getCode(), $e->getReportable(), $e->getExtraInfo(), $e->getRollback());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -172,7 +172,7 @@ class thermostat extends cora\crud {
|
|||||||
return true;
|
return true;
|
||||||
} catch(cora\exception $e) {
|
} catch(cora\exception $e) {
|
||||||
if($e->getCode() === 10511) {
|
if($e->getCode() === 10511) {
|
||||||
throw $e;
|
throw new cora\exception($e->getMessage(), $e->getCode(), $e->getReportable(), $e->getExtraInfo(), $e->getRollback());
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user