0
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2026-08-06 00:15:24 +08:00
discourse/docs/developer-guides/docs
Martin Brennan ea74b65aa5
DEV: Preserve existing errors in service model steps (#41896)
`ModelStep` revalidates changed models by calling `invalid?`, which
clears errors
added by the model producer before validations run. For example,
`UploadCreator`
can return an unsaved `Upload` containing an image-processing error;
`ModelStep`
then clears that error and may treat the `Upload` as valid.

Treat models that already contain errors as invalid without revalidating
them.
This preserves operation-specific errors for `on_model_errors` while
continuing
to validate changed models that do not already contain errors.

---------

Co-authored-by: Loïc Guitaut <loic@discourse.org>
2026-07-23 17:15:26 +10:00
..
01-introduction
02-development-environments DEV: Replace JS build system with Rolldown (#35963) 2026-05-29 11:11:55 +01:00
03-code-internals DEV: Preserve existing errors in service model steps (#41896) 2026-07-23 17:15:26 +10:00
04-plugins DEV: Use Meta image URLs in synced docs (#41670) 2026-07-13 18:27:36 -04:00
05-themes-components DEV: Add resolve_group_membership for theme object settings of group type (#41756) 2026-07-17 10:19:29 +10:00
06-general-guides DOCS: persona -> agent (#38617) 2026-03-16 16:38:55 +08:00
07-theme-developer-tutorial DEV: Docs for theme setting resolve_group_membership (#41537) 2026-07-08 17:02:38 +10:00
index.md