diff options
author | Colin Okay <colin@cicadas.surf> | 2022-10-28 07:15:52 -0500 |
---|---|---|
committer | Colin Okay <colin@cicadas.surf> | 2022-10-28 07:15:52 -0500 |
commit | 578e2fa0790a7c749e0f597bcdc6b5e4f776dfa2 (patch) | |
tree | 1db5347263817aa19723af8a9066457fae11bdbe /model.lisp | |
parent | 5b0c8784305b9a2bf34816b264a8d9c6968d0bcc (diff) |
Add: collaborator/editor managment on playlists
Diffstat (limited to 'model.lisp')
-rw-r--r-- | model.lisp | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -110,6 +110,15 @@ (hash-string pw (user-pwsalt user))) user)))) +(defun remove-editor (playlist editor) + (with-transaction () + (setf (playlist-editors playlist) + (delete editor (playlist-editors playlist))))) + +(defun add-editor (playlist editor) + (with-transaction () + (pushnew editor (playlist-editors playlist) :test #'eq))) + (defun destroy-invite (invite) (with-transaction () (bknr.datastore:delete-object invite))) |