1
0
Fork 0

- removed nethod to delete notifications using old API

new version of pleroma implements the same API as mastodon 3.x
- fixed command line switch to get notification for mentions.
This commit is contained in:
cage 2020-09-27 18:19:26 +02:00
parent 1bf02d1fda
commit 4bbb0184e1
4 changed files with 4 additions and 17 deletions

View File

@ -658,18 +658,16 @@ numerical indices identifying the option voting for"
:exclude-types exclude-types
:account-id account-id))
(defun mentions (max-id)
(defun mentions (max-id &optional (excluded-types '(:follow :favourite :reblog)))
"Get the latest mentions, starting from `min-id` (pass nil to get
the latest 15 mentions)."
(get-notifications :max-id max-id
:exclude-types '(:follow
:favourite
:reblog)))
:exclude-types excluded-types))
(defun-w-lock delete-notification (notification-id)
*client-lock*
"Delete a notification identified by `notification-id'"
(api-pleroma:delete-notification *client* notification-id))
(tooter:delete-notification *client* notification-id))
(defun sort-id< (list)
"Sort entities by id in descending order"

View File

@ -16,16 +16,6 @@
(in-package :api-pleroma)
(defgeneric delete-notification (object id))
(defmethod delete-notification ((object tooter:client) (id string))
(tooter:submit object
"/api/v1/notifications/dismiss"
:id id))
(defmethod delete-notification ((object tooter:client) (notification tooter:notification))
(delete-notification object (tooter:id notification)))
(defgeneric create-chat (object user-id))
(defmethod create-chat ((object tooter:client) (account-id string))

View File

@ -122,4 +122,4 @@
(when (getf options :check-follows-requests)
(setf *check-follow-requests* (getf options :check-follows-requests)))
(when (getf options :notify-mentions)
(setf *notify-mentions* (getf options :check-follows-requests))))))
(setf *notify-mentions* (getf options :notify-mentions))))))

View File

@ -1267,7 +1267,6 @@
:misc)
(:shadowing-import-from :misc :random-elt :shuffle)
(:export
:delete-notification
:chat-message
:message-id
:nreadp