Pieter Mans wrote:
Is there a quick way to to check for an object's existence in a collection?
collection.include?(object) or collection.find(object) depending on what collection you have, I guess.
Pieter Mans wrote:
Is there a quick way to to check for an object's existence in a collection?
collection.include?(object) or collection.find(object) depending on what collection you have, I guess.
correction, find on a collection works only for id.