diff options
author | Alexander_Kabui | 2024-08-07 17:51:45 +0300 |
---|---|---|
committer | Munyoki Kilyungi | 2024-08-09 11:55:16 +0300 |
commit | 5298ad1f8b498fbbc82ccfae7b1305458bbd0876 (patch) | |
tree | 4bf28cd8a9dd74d0d67ecc907ca1c6df7bd83ed1 | |
parent | 12b3d8158b807609f3f571cbf0603bb067878e9b (diff) | |
download | gn-guile-5298ad1f8b498fbbc82ccfae7b1305458bbd0876.tar.gz |
Fix naming for predicates.
-rw-r--r-- | web/view/markdown.scm | 4 | ||||
-rwxr-xr-x | web/webserver.scm | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/web/view/markdown.scm b/web/view/markdown.scm index e6d595d..5f3474c 100644 --- a/web/view/markdown.scm +++ b/web/view/markdown.scm @@ -69,7 +69,7 @@ (define (git-invoke repo-path . args) (apply system* "git" "-C" repo-path args)) -(define (is-repo? repo-path) +(define (git-repository? repo-path) (let ((data (git-invoke repo-path "rev-parse"))) (zero? data))) @@ -83,7 +83,7 @@ (unless (string=? prev-commit (get-latest-commit-sha1 repo)) (throw 'system-error (format #f "Commits do no match.Please pull in latest changes for current * ~a * and prev * ~a * " (get-latest-commit-sha1 repo) prev-commit))) - (if (is-repo? repo) + (if (git-repository? repo) (match (file-exists? (string-append repo "/" file-path)) (#t (with-output-to-file (string-append repo "/" file-path) diff --git a/web/webserver.scm b/web/webserver.scm index ded9997..9f278be 100755 --- a/web/webserver.scm +++ b/web/webserver.scm @@ -179,7 +179,7 @@ otherwise search for set/group data" (let* ((post-data (decode-request-json body)) (_ (for-each (lambda (target) - (is-invalid-data? post-data target) + (invalid-data? post-data target) ) '("filename" "content" "username" "email" "prev_commit"))) (file-name (assoc-ref post-data "filename")) (content (assoc-ref post-data "content")) |