gnu: fail2ban-service-type: Fix field name serialization.

* gnu/services/security.scm: Wrong condition in string-filter
function in fail2ban-jail-configuration-serialize-field-name.

Signed-off-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
This commit is contained in:
muradm 2022-08-29 16:51:18 +03:00 committed by Maxim Cournoyer
parent 58974e7b19
commit 80d9edb69d
No known key found for this signature in database
GPG key ID: 1260E46482E63562

View file

@ -127,7 +127,7 @@ (define (fail2ban-jail-configuration-serialize-field-name name)
(string-append "bantime." (substring name 9))))
((string-contains name "-")
(fail2ban-jail-configuration-serialize-field-name
(string-filter (lambda (c) (equal? c #\-)) name)))
(string-filter (lambda (c) (not (equal? c #\-))) name)))
(else name)))
(define (fail2ban-jail-configuration-serialize-string field-name value)