fix: surface nextcloud mail sync errors
This commit is contained in:
parent
b955e591d3
commit
3a0522ad2b
@ -509,5 +509,6 @@ def register(app) -> None:
|
|||||||
try:
|
try:
|
||||||
result = trigger_nextcloud_mail_sync(username, wait=wait)
|
result = trigger_nextcloud_mail_sync(username, wait=wait)
|
||||||
return jsonify(result)
|
return jsonify(result)
|
||||||
except Exception:
|
except Exception as exc:
|
||||||
return jsonify({"error": "failed to sync nextcloud mail"}), 502
|
message = str(exc).strip() or "failed to sync nextcloud mail"
|
||||||
|
return jsonify({"error": message}), 502
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user