From c322b6e5f5011d42a657334553ce0698c567ac2c Mon Sep 17 00:00:00 2001 From: Pjotr Prins Date: Wed, 23 Aug 2023 11:13:43 +0200 Subject: Refactoring URIs --- gn/data/group.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'gn') diff --git a/gn/data/group.scm b/gn/data/group.scm index 1505b21..3d31a0b 100644 --- a/gn/data/group.scm +++ b/gn/data/group.scm @@ -12,12 +12,13 @@ get-group-links )) -(define (get-group-links gnid) - "Return all the URIs that link to group info, e.g. for Mus_musculus" +(define (get-group-links gnid func) + "Return all the URIs that link to group info, e.g. for Mus_musculus. + Uses func to transform the link - if required." (let ([recs (car (cdr (compile-groups-meta)))] [uri (mk-gnid gnid)]) (filter-map (lambda (r) (if (string=? (second r) uri) - `(("ref" . ,(mk-id (car r)))) + (func (car r)) #f)) recs) )) -- cgit v1.2.3