diff options
author | Pjotr Prins | 2023-08-04 13:38:51 +0200 |
---|---|---|
committer | Pjotr Prins | 2023-08-04 13:38:51 +0200 |
commit | d7d9b55eb43b9b905de0419cd26569aaeea6fe5a (patch) | |
tree | aff8fdf4224afa5cd899945ea540292872e1da2b | |
parent | 601a247a72e308b310fb0525fc17f394a5e544e5 (diff) | |
download | genenetwork3-d7d9b55eb43b9b905de0419cd26569aaeea6fe5a.tar.gz |
Resolves mouse.json
-rwxr-xr-x | gn3-guile/web/webserver.scm | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/gn3-guile/web/webserver.scm b/gn3-guile/web/webserver.scm index 4cd049c..6059545 100755 --- a/gn3-guile/web/webserver.scm +++ b/gn3-guile/web/webserver.scm @@ -377,13 +377,14 @@ SELECT ?species ?p ?o WHERE { (render-json (get-species-meta))) (('GET "species") (render-json (get-species-meta))) - (('GET shortname) + (('GET id) (let ([names (get-species-shortnames (get-expanded-species))]) - (if (string-contains shortname ".json") - (if (member (string-replace-substring shortname ".json" "") names) - (render-json shortname) - ) - (render-json "doc")))) + (if + (match (string->list "mouse.json") + [(name ... #\. #\j #\s #\o #\n) (list->string name)] + [rest #f]) + (render-json name) + (render-json "WIP")))) (_ (not-found (request-uri request))) )) |