Skip to content

Instantly share code, notes, and snippets.

@mikeraimondi
Created August 14, 2013 23:18
Show Gist options
  • Save mikeraimondi/6236724 to your computer and use it in GitHub Desktop.
Save mikeraimondi/6236724 to your computer and use it in GitHub Desktop.
class IntervalWorker
def initialize(interval_id)
@interval_id = interval_id
end
def perform
interval = Interval.where(id: @interval_id).first
interval.complete! if interval.present?
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment