Issue description
Environment
Bug report without environment information will be ignored or closed.
- apisix version (cmd:
apisix version): 2.7
- OS (cmd:
uname -a): Darwin Kernel Version 20.3.0
- OpenResty / Nginx version (cmd:
nginx -V or openresty -V): openresty/1.19.3.1
- etcd version, if have (cmd: run
curl http://127.0.0.1:9090/v1/server_info to get the info from server-info API): 3.4.0
- apisix-dashboard version, if have: NAN
- luarocks version, if the issue is about installation (cmd:
luarocks --version): NAN
Minimal test code / Steps to reproduce the issue
Bug report without steps to reproduce will be ignored or closed.
-
I have a consumer, username is user

-
when I update this consumer by admin-api used mismatched username in path and body, update successfully

What's the actual result? (including assertion message & call stack if applicable)
What's the expected result?
IMO it should return HTTP code 400 when call admin-api to update consumer with mismatched username in path and body or user will get confused.
Issue description
Environment
Bug report without environment information will be ignored or closed.
apisix version): 2.7uname -a): Darwin Kernel Version 20.3.0nginx -Voropenresty -V): openresty/1.19.3.1curl http://127.0.0.1:9090/v1/server_infoto get the info from server-info API): 3.4.0luarocks --version): NANMinimal test code / Steps to reproduce the issue
Bug report without steps to reproduce will be ignored or closed.
I have a consumer, username is

userwhen I update this consumer by admin-api used mismatched username in path and body, update successfully
What's the actual result? (including assertion message & call stack if applicable)
What's the expected result?
IMO it should return HTTP code 400 when call admin-api to update consumer with mismatched username in path and body or user will get confused.