aboutsummaryrefslogtreecommitdiff
path: root/sx.el
diff options
context:
space:
mode:
Diffstat (limited to 'sx.el')
-rw-r--r--sx.el12
1 files changed, 12 insertions, 0 deletions
diff --git a/sx.el b/sx.el
index e5f81a4..d4c3ac2 100644
--- a/sx.el
+++ b/sx.el
@@ -56,6 +56,7 @@
question.link
question.upvoted
question.downvoted
+ question.question_id
user.display_name
comment.owner
comment.body_markdown
@@ -65,6 +66,10 @@
comment.creation_date
comment.upvoted
comment.score
+ comment.post_type
+ comment.post_id
+ comment.comment_id
+ answer.answer_id
answer.last_editor
answer.link
answer.owner
@@ -193,6 +198,13 @@ Return the result of BODY."
(add-text-properties p (point) ,properties)
result))
+(defun sx--user-@name (user)
+ "Get the `display_name' of USER prepended with @."
+ (sx-assoc-let user
+ (when (stringp .display_name)
+ (concat "@" .display_name))))
+
+
;;; Assoc-let
(defun sx--site (data)
"Get the site in which DATA belongs.