mirror of
https://github.com/C9Glax/tranga.git
synced 2025-09-10 20:08:19 +02:00
BaseWorker, BaseWorkerWithContext DoWork, call: Scope setting
TrangaBaseContext Sync return with success state and exception message
This commit is contained in:
@@ -88,8 +88,8 @@ public class MangaConnectorController(IServiceScope scope) : Controller
|
||||
|
||||
connector.Enabled = Enabled;
|
||||
|
||||
if(context.Sync().Result is { } errorMessage)
|
||||
return StatusCode(Status500InternalServerError, errorMessage);
|
||||
if(context.Sync().Result is { success: false } result)
|
||||
return StatusCode(Status500InternalServerError, result.exceptionMessage);
|
||||
return Accepted();
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user