app/controllers/devise/invitations_controller.rb in devise_invitable-1.1.5 vs app/controllers/devise/invitations_controller.rb in devise_invitable-1.1.6
- old
+ new
@@ -36,10 +36,11 @@
# PUT /resource/invitation
def update
self.resource = resource_class.accept_invitation!(resource_params)
if resource.errors.empty?
- set_flash_message :notice, :updated
+ flash_message = resource.active_for_authentication? ? :updated : :updated_not_active
+ set_flash_message :notice, flash_message
sign_in(resource_name, resource)
respond_with resource, :location => after_accept_path_for(resource)
else
respond_with_navigational(resource){ render :edit }
end