fix: wrong icm fallback is used when configured icm throws errors on SSR #1519
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR Type
[ x ] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no API changes)
[ ] Build-related changes
[ ] CI-related changes
[ ] Documentation content changes
[ ] Application / infrastructure changes
[ ] Other:
What Is the Current Behavior?
On SSR the PWA renders a given page. It sets a transferState, which will be used on browser side afterwards. When an error for the given ICM occurs on SSR (e.g. wrong certificate), it is possible, that wrong error properties are set in state. This can lead to the problem, that
JSON.stringify(state)
throws an error due to the incorrect state. The outcome is, that no transferState is set on SSR. The browser side cannot retrieve the configured ICM anymore and incorrectly use the fallback (configured in environment..ts).Issue Number: Closes #
What Is the New Behavior?
error.reducer.ts
are reduced to the defined set of the predefinedHttpError
interfaceicmBaseUrl
in production modeDoes this PR Introduce a Breaking Change?
[ x ] Yes
[ ] No
No fallback for icmBaseUrl in production mode. The given option
disableOption
to apply configurations can be removed in order to retain the old behavior.Other Information
AB#90030