Looking to see if there is a better way to redirect a query string other than using if in this situation.
Example URL: http://foo.com/?p=123 to http://foo.com/new
Current using if:
location / {
if ($args ~ p=123) {
rewrite ^ https://foo.com/new? permanent;
}
}