Skip to content

Instantly share code, notes, and snippets.

@indrekj
Created May 5, 2012 20:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save indrekj/2605319 to your computer and use it in GitHub Desktop.
Save indrekj/2605319 to your computer and use it in GitHub Desktop.
class UserRegistrationService
def initialize(params)
@params = params
end
def register
user = User.new(@params)
if user.save
# send_email
# do other after_create stuff you need
end
user
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment