RFR: 1679: Make username and prefix optional config options for slack log handler

Erik Joelsson erikj at openjdk.org
Wed Nov 16 20:48:37 UTC 2022


In [SKARA-1660](https://bugs.openjdk.org/browse/SKARA-1660) I added the new "prefix" config option for the slack log handler. This will be used instead of the username field. The problem is that neither field was made optional in the config parser, so now we have to configure both, regardless of if we want them or not. The actual handler logic treats them as optional, but the config parser throws NPE.

This patch adds null checks to avoid the NPEs.

-------------

Commit messages:
 - Fix null check
 - SKARA-1679

Changes: https://git.openjdk.org/skara/pull/1421/files
 Webrev: https://webrevs.openjdk.org/?repo=skara&pr=1421&range=00
  Issue: https://bugs.openjdk.org/browse/SKARA-1679
  Stats: 11 lines in 1 file changed: 3 ins; 0 del; 8 mod
  Patch: https://git.openjdk.org/skara/pull/1421.diff
  Fetch: git fetch https://git.openjdk.org/skara pull/1421/head:pull/1421

PR: https://git.openjdk.org/skara/pull/1421


More information about the skara-dev mailing list