debian-mirror-gitlab/lib/constraints/user_url_constrainer.rb
2017-08-17 22:00:37 +05:30

5 lines
154 B
Ruby

class UserUrlConstrainer
def matches?(request)
User.find_by_full_path(request.params[:username], follow_redirects: request.get?).present?
end
end