Commit 83da39ee authored by Robert Knight's avatar Robert Knight

Remove unnecessary code for checking type of `annotation.references` field

We now have much more control over how fields are rendered to JSON on
the server and as a result, this field is always either unset or an
array of strings.
parent 61974f4e
......@@ -471,16 +471,7 @@ function AnnotationController(
* Creates a new message in reply to this annotation.
*/
vm.reply = function() {
var references = domainModel.references || [];
// TODO: Remove this check once we have server-side code to ensure that
// references is always an array of strings.
if (typeof references === 'string') {
references = [references];
}
references = references.concat(domainModel.id);
var references = (domainModel.references || []).concat(domainModel.id);
var reply = annotationMapper.createAnnotation({
references: references,
uri: domainModel.uri
......
Markdown is supported
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