"Trusted Origins" redirect goes to wrong URL

Hi everyone,
I have a webapp that I run from localhost (development) and a website. Authentication works fine from localhost (redirect after custom login works fine), but when I log in from the website, the redirect goes to “localhost:8080” instead of back to the website. Here’s how my API/TrustedOrigins looks:

Any help appreciated!

You control the redirect_uri in your code. Make sure you update it to your production URL before you deploy it.