mirror of
https://git.savannah.gnu.org/git/guix.git
synced 2025-02-07 11:29:59 +01:00
services: Streamline or eliminate some match-lambda patterns.
These were spot while working on a fix for commit 543d971ed2
("services:
configuration: Re-order generated record fields").
* gnu/services/web.scm (php-fpm-accounts): Remove extraneous trailing dummy
catchall patterns.
(agate-accounts): Access the configuration fields directly since there are
only two, which is less error-prone.
This commit is contained in:
parent
238248aac9
commit
7ae4cfa5aa
1 changed files with 18 additions and 19 deletions
|
@ -987,7 +987,7 @@ and the back-end of a Web service.")))
|
|||
|
||||
(define php-fpm-accounts
|
||||
(match-lambda
|
||||
(($ <php-fpm-configuration> php socket user group socket-user socket-group _ _ _ _ _ _)
|
||||
(($ <php-fpm-configuration> php socket user group socket-user socket-group)
|
||||
`(,@(if (equal? group "php-fpm")
|
||||
'()
|
||||
(list (user-group (name "php-fpm") (system? #t))))
|
||||
|
@ -2143,10 +2143,9 @@ root=/srv/gemini
|
|||
(stop #~(make-kill-destructor)))))))
|
||||
|
||||
(define agate-accounts
|
||||
(match-lambda
|
||||
(($ <agate-configuration> _ _ _ _ _
|
||||
_ _ _ _
|
||||
_ user group _)
|
||||
(lambda (config)
|
||||
(let ((group (agate-configuration-group config))
|
||||
(user (agate-configuration-user config)))
|
||||
`(,@(if (equal? group "agate")
|
||||
'()
|
||||
(list (user-group (name "agate") (system? #t))))
|
||||
|
|
Loading…
Add table
Reference in a new issue