From d41ea2faa69e8d22c0e57f06641ef066cf059774 Mon Sep 17 00:00:00 2001 From: Juanfran Date: Wed, 12 Nov 2014 09:33:58 +0100 Subject: [PATCH] check if watcher is defined before print --- app/coffee/modules/common/components.coffee | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/coffee/modules/common/components.coffee b/app/coffee/modules/common/components.coffee index 3cd5bb3d..4f0e4bf7 100644 --- a/app/coffee/modules/common/components.coffee +++ b/app/coffee/modules/common/components.coffee @@ -175,6 +175,7 @@ WatchersDirective = ($rootscope, $confirm, $repo) -> <% }; %> <% _.each(watchers, function(watcher) { %> + <% if(watcher) { %>
@@ -191,6 +192,7 @@ WatchersDirective = ($rootscope, $confirm, $repo) -> <% }; %>
+ <% } %> <% }); %> """) @@ -214,6 +216,7 @@ WatchersDirective = ($rootscope, $confirm, $repo) -> watchers: watchers isEditable: isEditable() } + html = template(ctx) $el.html(html)