Skip to content

Instantly share code, notes, and snippets.

@gertig
Created March 31, 2011 01:25
Show Gist options
  • Save gertig/895655 to your computer and use it in GitHub Desktop.
Save gertig/895655 to your computer and use it in GitHub Desktop.
class InvitationsController < Devise::InvitationsController
include Devise::Controllers::InternalHelpers #not sure if this is necessary
# POST /resource/invitation
def create
#Assuming the user_id of the gifted user is = 1
if current_user.id == 1
current_user.increment!(:invitation_limit)
end
super
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment