aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--module/entry-points/server.scm12
1 files changed, 10 insertions, 2 deletions
diff --git a/module/entry-points/server.scm b/module/entry-points/server.scm
index 706f2699..b7d4afff 100644
--- a/module/entry-points/server.scm
+++ b/module/entry-points/server.scm
@@ -180,11 +180,19 @@
(return (build-response code: 400)
(format #f "~?~%" fmt args)))))
+ ;; NOTE Posibly defer save to a later point.
+ ;; That would allow better asyncronous preformance.
+ ((@ (output vdir) save-event) event)
+
(format (current-error-port)
"Event inserted ~a~%" (prop event 'UID))
- (return '((content-type text/plain))
- "Event inserted\r\n"))))
+ (return '((content-type application/xml))
+ (with-output-to-string
+ (lambda ()
+ (sxml->xml
+ `(properties
+ (uid (text ,(prop event 'UID)))))))))))
;; Get specific page by query string instead of by path.
;; Useful for <form>'s, since they always submit in this form, but also