From bdc817a068f3145ca043c501500939e141cd5c55 Mon Sep 17 00:00:00 2001 From: eta Date: Tue, 7 Apr 2020 14:45:53 +0100 Subject: [PATCH] oops, don't break photos --- stuff.lisp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/stuff.lisp b/stuff.lisp index 275e744..f2f5d6c 100644 --- a/stuff.lisp +++ b/stuff.lisp @@ -1035,6 +1035,7 @@ Returns three values: avatar data (as two values), and a generalized boolean spe (defun get-contact-status (uid localpart) "Get the contact status text for LOCALPART, a possible contact for the user with ID UID." + (declare (type integer uid) (type string localpart)) (with-prepared-statements ((get-stmt "SELECT status FROM user_contacts WHERE user_id = ? AND wa_jid = ?")) (bind-parameters get-stmt uid localpart) @@ -1069,9 +1070,9 @@ Returns three values: avatar data (as two values), and a generalized boolean spe (cxml:with-element "x" (cxml:attribute "xmlns" +vcard-avatar-ns+) (if avatar-sha1 - (cxml:with-element "photo") (cxml:with-element "photo" - (cxml:text avatar-sha1))))) + (cxml:text avatar-sha1)) + (cxml:with-element "photo")))) (progn (unless noretry (unless avatar-sha1