MM-13718 Prevent files from being attached to multiple posts (#10094)
* MM-13718 Prevent files from being attached to multiple posts * Switch back to non-batched AttachToPost * Change status code when failing to attach a file
Этот коммит содержится в:
коммит произвёл
Christopher Speller
родитель
f12680103a
Коммит
6325c5b569
@@ -291,6 +291,9 @@ func (o *Post) PreCommit() {
|
||||
}
|
||||
|
||||
o.GenerateActionIds()
|
||||
|
||||
// There's a rare bug where the client sends up duplicate FileIds so protect against that
|
||||
o.FileIds = RemoveDuplicateStrings(o.FileIds)
|
||||
}
|
||||
|
||||
func (o *Post) MakeNonNil() {
|
||||
|
||||
Ссылка в новой задаче
Block a user