X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/ff97501ed01488f8ff8e9d2e7b93b4f295f71725..ee53b7a298e75ac4c75866d6edea0a2611bdb663:/app/controllers/api_controller.rb diff --git a/app/controllers/api_controller.rb b/app/controllers/api_controller.rb index c36ded1c0..9324a8ed5 100644 --- a/app/controllers/api_controller.rb +++ b/app/controllers/api_controller.rb @@ -305,7 +305,7 @@ class ApiController < ApplicationController def permissions @permissions = if current_token.present? ClientApplication.all_permissions.select { |p| current_token.read_attribute(p) } - elsif @user + elsif current_user ClientApplication.all_permissions else []