Deny anonymous access

pull/1463/head
Hagen Schink 11 years ago
parent 7aed23e438
commit 6ce1f68d7e
  1. 6
      app/controllers/api/v2/custom_fields_controller.rb

@ -35,7 +35,7 @@ module Api
accept_key_auth :index, :show
before_filter :require_permissions
before_filter :require_authentication
def index
wp_fields = WorkPackageCustomField.find :all,
@ -63,8 +63,8 @@ module Api
protected
def require_permissions
deny_access unless User.current.allowed_to? :edit_project, nil, :global => true
def require_authentication
deny_access if User.current.anonymous?
end
end

Loading…
Cancel
Save