Fix some select-build-servers calls

This commit is contained in:
Christopher Baines 2023-12-04 11:09:46 +00:00
parent a3ec1f326d
commit 8a8dccf2d8
3 changed files with 5 additions and 4 deletions

View File

@ -326,7 +326,7 @@
(match method-and-path-components
(('GET "build-servers")
(let ((build-servers
(with-resource-from-pool (connection-pool) conn
(call-with-resource-from-pool (connection-pool)
select-build-servers)))
(render-build-servers mime-types
build-servers)))

View File

@ -42,8 +42,8 @@
(define parse-build-server
(lambda (v)
(letpar& ((build-servers
(with-resource-from-pool (connection-pool) conn
select-build-servers)))
(call-with-resource-from-pool (connection-pool)
select-build-servers)))
(or (any (match-lambda
((id url lookup-all-derivations? lookup-builds?)
(if (eq? (string->number v)

View File

@ -85,7 +85,8 @@
(define (parse-build-server v)
(letpar& ((build-servers
(with-resource-from-pool (connection-pool) conn select-build-servers)))
(call-with-resource-from-pool (connection-pool)
select-build-servers)))
(or (any (match-lambda
((id url lookup-all-derivations? lookup-builds?)
(if (eq? (string->number v)