pdata loss in login flow on 2.0.4
Concerned version
Version: %2.0.4 only
Summary
When using 2.0.4 on a fresh install, the missing Finland icon on the portal will trigger a 404, and thus clear pdata as because of af707c5b
This breaks any non-trivial issuer+login workflows (we found this while investigating SAML issues), and probably any other features using pdata.
Most of our existing users won't be affected, unless they updated their lemonldap-ng.ini to add Finnish language to the portal.
The missing flag is already fixed in 2.0 with c65e22dc, so any version after 2.0.5 will probably not be affected either, unless the user added invalid URLS to their portal templates.
Logs
Possible fixes
A trivial workaround is to remove finnish from the portal languages if you are not interested in it, or add the missing flag icon if you are.
We should probably reconsider af707c5b however, because errors while retrieving portal elements should not break the login flow like this.
Perhaps the portal's 404 errors should be handled differently from handler's 404? Or perhaps we should try to detect if the 404 is happening in full page or in a background query (image/css/js fetch, AJAX query...).