Showing the changes to assets/javascripts (2 of 2 files). Show all
Unified · Split
| @@ -167,7 +167,7 @@ class app.views.DocList extends app.View · 166 unmodified lines | |||
| 167 | else if slug = event.target.getAttribute('data-enable') | 167 | else if slug = event.target.getAttribute('data-enable') |
| 168 | $.stopEvent(event) | 168 | $.stopEvent(event) |
| 169 | doc = app.disabledDocs.findBy('slug', slug) | 169 | doc = app.disabledDocs.findBy('slug', slug) |
| 170 | app.enableDoc(doc, @onEnabled, @onEnabled) | 170 | app.enableDoc(doc, @onEnabled, @onEnabled) if doc |
| 171 | return | 171 | return |
| 172 | 172 | ||
| 173 | onEnabled: => | 173 | onEnabled: => |
| @@ -65,4 +65,4 @@ class app.views.Results extends app.View · 64 unmodified lines | |||
| 65 | if slug = event.target.getAttribute('data-enable') | 65 | if slug = event.target.getAttribute('data-enable') |
| 66 | $.stopEvent(event) | 66 | $.stopEvent(event) |
| 67 | doc = app.disabledDocs.findBy('slug', slug) | 67 | doc = app.disabledDocs.findBy('slug', slug) |
| 68 | app.enableDoc(doc, @onDocEnabled.bind(@, doc), $.noop) | 68 | app.enableDoc(doc, @onDocEnabled.bind(@, doc), $.noop) if doc |