This PR fixes a potential panic if creating a shortcut fails (would result in the shortcut being a nil pointer, which we obviously cannot delete). It also validates that the document status is WIP before allowing creating a review to go through - this could potentially result in multiple reviews for a document (the UI makes this difficult but it was still possible via the API).
This PR fixes a potential panic if creating a shortcut fails (would result in the shortcut being a nil pointer, which we obviously cannot delete). It also validates that the document status is WIP before allowing creating a review to go through - this could potentially result in multiple reviews for a document (the UI makes this difficult but it was still possible via the API).