Skip to content

Commit

Permalink
Simplify filter definition
Browse files Browse the repository at this point in the history
  • Loading branch information
csillag committed Mar 27, 2015
1 parent f3f5add commit f252a65
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion h/static/scripts/controllers.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ class ViewerController
method: 'scrollToAnnotation'
params: annotation.$$tag

$scope.notOrphan = -> (container) -> !container?.message?.$orphan
$scope.notOrphan = (container) -> !container?.message?.$orphan

$scope.shouldShowThread = (container) ->
if annotationUI.hasSelectedAnnotations() and not container.parent.parent
Expand Down
2 changes: 1 addition & 1 deletion h/templates/client/viewer.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
ng-mouseenter="focus(child.message)"
ng-click="scrollTo(child.message)"
ng-mouseleave="focus()"
ng-repeat="child in threadRoot.children | filter:notOrphan() | orderBy : sort.predicate"
ng-repeat="child in threadRoot.children | filter:notOrphan | orderBy : sort.predicate"
ng-show="shouldShowThread(child) && (count('edit') || count('match') || !threadFilter.active())">
</li>
</ul>
Expand Down

0 comments on commit f252a65

Please sign in to comment.