On Tue, Jul 30, 2019 at 10:03 AM 'Robin Jansohn' via Jenkins
Developers <[email protected]> wrote:
> Can this sort of problem be avoided/fixed?
You can replace uses of `path` with a getter returning `path != null ?
path : "/manager/text"`. Or you can add a
private Object readResolve() {
if (path == null) {
path = "/manager/text";
}
return this;
}
which will do the same but also ensure that if the configuration is
opened and resaved that a legal value for `path` will be written.
Besides checking for null you may need to check for `path.isEmpty()`,
in case the bad commit has already been released and some users who
resaved the form without touching this field may have `config.xml`
files with
<path></path>
if that is in fact not a legal value.
--
You received this message because you are subscribed to the Google Groups
"Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-dev/CANfRfr0M055QJsorX6K-F%2B%3DuoPcnw-Z9w97%3DzJRo8-b62y0agg%40mail.gmail.com.