mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-08-15 16:02:28 +02:00
[bugfix] Fix 404 on status delete redraft (#668)
* add unattach function to media processor * call delete or unattach appropriately unattach from client api, delete from federated api * typo fix
This commit is contained in:
@ -284,7 +284,12 @@ func (p *processor) processDeleteStatusFromClientAPI(ctx context.Context, client
|
||||
statusToDelete.Account = clientMsg.OriginAccount
|
||||
}
|
||||
|
||||
if err := p.wipeStatus(ctx, statusToDelete); err != nil {
|
||||
// don't delete attachments, just unattach them;
|
||||
// since this request comes from the client API
|
||||
// and the poster might want to use the attachments
|
||||
// again in a new post
|
||||
deleteAttachments := false
|
||||
if err := p.wipeStatus(ctx, statusToDelete, deleteAttachments); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user