Prefill logs error when trying to prefill data not appliccable to user #302
Labels
kind/bug
Something isn't working
org/srf
Issues relevant for Statens Sivilrettsforvaltning
status/triage
Description of the bug
Applications may be used for both organisations and people and need to supply prefill for both types of users.
Currently if a person tries to start an instance of an app where some fields are prefilled from ER prefill will log the absence of an organisation as an Error. The same happens if a oraganisation starts an instance of an app with prefill from DSF.
For an app used for both organisations and people with prefill from ER and DSF, to cover both users, all traces will contain a error log from Prefill with either the error
Could not prefill from DSF, person is not defined
orCould not prefill from ER, organisation is not defined
.The only way currently to avoid these is to turn off all error logs from prefill. This could potentially hide other errors during prefill and leave the logs lacking vital information when investigating an error.
We should consider if the error messages mentioned above should be changed to warnings making it possible to filter them out and still keep the error logs.
Steps To Reproduce
Additional Information
No response
The text was updated successfully, but these errors were encountered: