Open ozobken opened 5 years ago
The D
is hard-cleared for p2p topics. This feature has to be coded explicitly.
Hmm - That's weird - why treat P2P conversations differently to groups? That seems like extra work for the backend. I guess I can work around this by making all conversations groups, but that's much harder to set up
Independently, though - can D be added to the defacs for a new user, so that it's passed as the default to groups if chosen, since this mechanism already works?
Hmm - That's weird - why treat P2P conversations differently to groups?
Because there is no single owner there.
I guess I can work around this by making all conversations groups.
That probably won't work as expected because you would have to assign one user to be the owner. The other user won't be able to delete the messages.
The idea is to add an option for a user in p2p topics to delete own messages. That's going to take a bit of work through.
can D be added to the defacs for a new user
That's easy to do, but then the user with the D
permission will be able to delete messages sent by either user.
The option for a user in p2p topics to delete own messages is not too hard, it's probably a couple of days of my time. I just need to find time.
That would be cool - I'm integrating message expiry on my app, and I want the first endpoint that is doing the expiry to be able to delete the messages from the backend for a conversation. As an alternative, the backend could implement the expiry :), but that's a separate feature request.
Message expiration is on the road map. It's certainly a very useful feature.
Just a quick followup - did expiry or these Defacs changes make it in?
No work was done on these features.
Subject of the issue
I want to make it possible for P2P and group users to be able to hard delete messages in the conversation, the docs suggest that on new user creation, in the {acc} you can set a different 'defacs' to allow this. If I try and create a new users with 'defacs' of "JRWSPAD", it's created with "JRWPA"
Also, If I manually update the database to add the 'D' (to the users table, access column), when the P2P channel is subequently created, only one user gets 'D' permission, the other doesn't. Is this expected behaviour? How can we allow 'D' access to P2P for all participants?
(Good news is, after I hack the db, it seems to work as expected for groups - the 'D' gets passed to the group {sub} and if the group was created with 'D' allowed, then it's granted, but it's still not possible to set the defacs for the user with 'D' in the {acc} )
Is this a bug report of a feature request?
Your environment
Server-side
Client-side
Steps to reproduce
Make a new user with {acc} and acc.desc containing defacs.auth of "JRWSPAD"
Expected behaviour
Should set the defacs in the user to "JRWSPAD"
Actual behaviour
Sets the user's access to {"Auth":"JRWPA","Anon":"N"}
Server-side log
Client-side log
Even if I hack the database to allow 'D' for both users 'defacs' when the P2P is created, one user gets
the other side gets: