Checking to see if a listing exists

find_or_create_by is your friend (Dynamic attribute-based finders at ActiveRecord::Base)