Skip to content

Instantly share code, notes, and snippets.

@okdas
Created April 2, 2015 15:00
Show Gist options
  • Save okdas/6408958c0cce86e50a98 to your computer and use it in GitHub Desktop.
Save okdas/6408958c0cce86e50a98 to your computer and use it in GitHub Desktop.
$scope.triggersByProject = (trigger) ->
# Match by hostnames in project <-> trigger's host name.
if $.inArray(trigger.host.name, $scope.hosts) is not -1 then yes else no
$scope.triggersByProject = function(trigger) {
if ($.inArray(trigger.host.name, $scope.hosts) === !-1) {
return true;
} else {
return false;
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment