mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-30 20:49:20 +03:00
Sieve: use Optional chaining operator
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Optional_chaining
This commit is contained in:
parent
3a1046f215
commit
e1426b484e
6 changed files with 12 additions and 13 deletions
|
|
@ -58,7 +58,7 @@ window.Sieve = {
|
|||
Remote.request('FiltersScriptDelete',
|
||||
(iError, data) => {
|
||||
if (iError) {
|
||||
setError((data && data.ErrorMessageAdditional) || getNotification(iError));
|
||||
setError(data?.ErrorMessageAdditional || getNotification(iError));
|
||||
} else {
|
||||
scripts.remove(script);
|
||||
}
|
||||
|
|
@ -73,7 +73,7 @@ window.Sieve = {
|
|||
Remote.request('FiltersScriptActivate',
|
||||
(iError, data) => {
|
||||
if (iError) {
|
||||
setError((data && data.ErrorMessageAdditional) || iError)
|
||||
setError(data?.ErrorMessageAdditional || iError)
|
||||
} else {
|
||||
scripts.forEach(script => script.active(script.name() === name));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue