Editorial workflow Improvements (#212)

* Merge conflicts automatically. Closes #208
* removed unpublished entry route
All entries (either under editorial workflow or not) go through the same edit route.
This commit is contained in:
Cássio Souza
2017-01-11 20:58:15 -02:00
committed by GitHub
parent c40171820f
commit 48d8077ff0
19 changed files with 279 additions and 155 deletions

View File

@ -0,0 +1,11 @@
export const API_ERROR = 'API_ERROR';
export default class APIError extends Error {
constructor(message, status, api) {
super(message);
this.message = message;
this.status = status;
this.api = api;
this.name = API_ERROR;
}
}

View File

@ -0,0 +1,10 @@
export const EDITORIAL_WORKFLOW_ERROR = 'EDITORIAL_WORKFLOW_ERROR';
export default class EditorialWorkflowError extends Error {
constructor(message, notUnderEditorialWorkflow) {
super(message);
this.message = message;
this.notUnderEditorialWorkflow = notUnderEditorialWorkflow;
this.name = EDITORIAL_WORKFLOW_ERROR;
}
}

View File

@ -0,0 +1,3 @@
export { default as APIError } from './APIError';
export { default as EditorialWorkflowError } from './EditorialWorkflowError';