Skip to content

Instantly share code, notes, and snippets.

@aishek
Created August 17, 2016 08:15
Show Gist options
  • Save aishek/f3cf006179c520e17ff754abdab85a2f to your computer and use it in GitHub Desktop.
Save aishek/f3cf006179c520e17ff754abdab85a2f to your computer and use it in GitHub Desktop.
special_case.rb
def send_pick_up_email_async(order)
return if order.from_office?
if order.long?
Order::PickUpEmailWorker.perform_async(order.id)
else
Order::PickUpAndDropOffEmailWorker.perform_async(order.id)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment