Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save nkpart/73658 to your computer and use it in GitHub Desktop.
Save nkpart/73658 to your computer and use it in GitHub Desktop.
def assign_nesting_resources
@hammock_nesting_scopes.map {|scope|
scope.kick
}.confirm {|kicked_scopes|
kicked_scopes.all? { |results| results.length == 1 }
}.map { |kicked_scopes|
kicked_scopes.map {|results|
results.first
}.each {|result|
assign_entity result
}.empty?
}
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment