mirror of
https://github.com/discourse/discourse.git
synced 2025-05-21 18:12:32 +08:00
FEATURE: Extend topic update API scope to allow status updates (#19654)
Allow an API key created with topic:update API scope to make updates to topic status. This change also introduces an optional category_id scope param.
This commit is contained in:
@ -59,7 +59,7 @@ class RouteMatcher
|
||||
|
||||
params.all? do |param|
|
||||
param_alias = aliases&.[](param)
|
||||
allowed_values = [allowed_param_values[param.to_s]].flatten
|
||||
allowed_values = [allowed_param_values.fetch(param.to_s, [])].flatten
|
||||
|
||||
value = requested_params[param.to_s]
|
||||
alias_value = requested_params[param_alias.to_s]
|
||||
|
Reference in New Issue
Block a user