mirror of
https://github.com/zadam/trilium.git
synced 2025-11-02 03:16:11 +01:00
throwException instead of throwing exceptions manually (includes stacktrace)
This commit is contained in:
@@ -30,6 +30,10 @@ function showError(message) {
|
||||
});
|
||||
}
|
||||
|
||||
function throwError(message) {
|
||||
throw new Error(message + ':' + new Error().stack);
|
||||
}
|
||||
|
||||
function getDateFromTS(timestamp) {
|
||||
// Date accepts number of milliseconds since epoch so UTC timestamp works without any extra handling
|
||||
// see https://stackoverflow.com/questions/4631928/convert-utc-epoch-to-local-date-with-javascript
|
||||
|
||||
Reference in New Issue
Block a user