mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-07 01:54:22 +00:00
Merge pull request #8108 from tdonohue/dont_swallow_exceptions
Ensure SubmissionService doesn't swallow root exceptions
This commit is contained in:
@@ -250,7 +250,7 @@ public class SubmissionService {
|
||||
id = Integer.parseInt(split[1]);
|
||||
wsi = workspaceItemService.find(context, id);
|
||||
} catch (NumberFormatException e) {
|
||||
throw new UnprocessableEntityException("The provided workspaceitem URI is not valid");
|
||||
throw new UnprocessableEntityException("The provided workspaceitem URI is not valid", e);
|
||||
}
|
||||
if (wsi == null) {
|
||||
throw new UnprocessableEntityException("Workspace item is not found");
|
||||
@@ -265,7 +265,7 @@ public class SubmissionService {
|
||||
wi = workflowService.start(context, wsi);
|
||||
} catch (IOException e) {
|
||||
throw new RuntimeException("The workflow could not be started for workspaceItem with" +
|
||||
"id: " + id);
|
||||
" id: " + id, e);
|
||||
}
|
||||
|
||||
return wi;
|
||||
|
Reference in New Issue
Block a user