Sieve: use Optional chaining operator

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Optional_chaining
This commit is contained in:
the-djmaze 2022-05-21 23:58:46 +02:00
parent 3a1046f215
commit e1426b484e
6 changed files with 12 additions and 13 deletions

View file

@ -80,7 +80,7 @@ export class SieveScriptPopupView extends rl.pluginPopupView {
if (iError) {
self.saveError(true);
self.errorText((data && data.ErrorMessageAdditional) || getNotification(iError));
self.errorText(data?.ErrorMessageAdditional || getNotification(iError));
} else {
script.exists() || scripts.push(script);
script.exists(true);