Equality

is there a better way to test for equality than this

user1.interests.collect(&id).sort == user2.interests.collect(&id).sort

TIA

GP