Commit d94da6d8 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

problematic projectId error is not reportable by the user

parent c31bae29
......@@ -23,6 +23,7 @@ var SelectionContextMenu = require('./gui/SelectionContextMenu');
var GuiConnector = require('./GuiConnector');
var ServerConnector = require('./ServerConnector');
var SecurityError = require('./SecurityError');
var ValidationError = require('./ValidationError');
var MolArt = require('./map/structure/MolArt');
......@@ -489,7 +490,7 @@ function create(params) {
if (project === null) {
var message = "Project with given id doesn't exist.";
message += "<p>Please go to <a href='" + ServerConnector.getServerBaseUrl() + "'>default map</a>";
return Promise.reject(new Error(message));
return Promise.reject(new ValidationError(message));
}
params.setProject(project);
var promise = Promise.resolve();
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment