To fix this, create a file
~/.local/bin/browser (or whereever you prefer it to be) with
#!/bin/sh x-www-browser "$@" exit 0
x-www-browser with whatever browser you would like to be launched. The
exit 0 suppresses the error message.
exo-preferred-applications and select the newly created script as default browser.
Don’t let the browser set itself as default browser, because this would revert these settings.
Thanks to Jonas.