From 7ad46f7e04590b396e79888193585a697ca5cceb Mon Sep 17 00:00:00 2001 From: Marius Balteanu Date: Thu, 25 Jan 2024 15:31:49 +0000 Subject: [PATCH] Adds deprecation warning when an empty status param (status=) is used to get all users from API (#40099). git-svn-id: https://svn.redmine.org/redmine/trunk@22633 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/controllers/users_controller.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb index 18c012d60..f512f93f8 100644 --- a/app/controllers/users_controller.rb +++ b/app/controllers/users_controller.rb @@ -48,6 +48,7 @@ class UsersController < ApplicationController # API backwards compatibility: handle legacy filter parameters unless request.format.html? if params.include?(:status) && params[:status].blank? + ActiveSupport::Deprecation.warn "Getting all users from API using an empty status param (status=) is deprecated and it will be removed in Redmine 6.0. Please use \"status=*\"." @query.add_filter 'status', '*' end if name = params[:name].presence -- 2.39.5