Commit aa5327a5 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Fix project_limit being ignored on signup

parent 35139023
...@@ -12,9 +12,17 @@ class RegistrationsController < Devise::RegistrationsController ...@@ -12,9 +12,17 @@ class RegistrationsController < Devise::RegistrationsController
end end
end end
protected
def build_resource(hash=nil)
super
self.resource.projects_limit = Gitlab.config.gitlab.default_projects_limit
self.resource
end
private private
def signup_enabled? def signup_enabled?
redirect_to new_user_session_path unless Gitlab.config.gitlab.signup_enabled redirect_to new_user_session_path unless Gitlab.config.gitlab.signup_enabled
end end
end end
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment