Added custom message in case of error

git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/user/workspace-tree-widget@144548 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Francesco Mangiacrapa 2017-03-02 17:13:52 +00:00
parent 9a3f4f9a12
commit b325553df9
1 changed files with 4 additions and 0 deletions

View File

@ -4085,6 +4085,10 @@ public class GWTWorkspaceServiceImpl extends RemoteServiceServlet implements GWT
if (e instanceof FileNotVersionedException)
throw new Exception(e.getMessage());
if(e instanceof InsufficientPrivilegesException)
throw new Exception(e.getMessage());
workspaceLogger.error("Error in server during perform operation on versioning on file id: "+fileId, e);
String error = ConstantsExplorer.SERVER_ERROR +" updating versioning of file id: "+fileId;
throw new Exception(error);