diff --git a/source/UI/js/Video/VideoAnnotationPanel.js b/source/UI/js/Video/VideoAnnotationPanel.js index 90e9cc57..cc788b0b 100644 --- a/source/UI/js/Video/VideoAnnotationPanel.js +++ b/source/UI/js/Video/VideoAnnotationPanel.js @@ -1720,10 +1720,10 @@ Ox.VideoAnnotationPanel = function(options, self) { // id might have changed if new annotation was created if (annotation.id) { self.options.selected = annotation.id; - var layer = Ox.getObjectById(self.options.layers, annotation.layer) - var item = Ox.getObjectById(layer.items, annotation.id) + var layer = Ox.getObjectById(self.options.layers, annotation.layer); + var item = Ox.getObjectById(layer.items, annotation.id); if (!item) { - layer.items.push(annotation) + layer.items.push(annotation); self.annotations = getAnnotations(); } }