Adding 'MessageHasBeenDeleted' hook to plugins (#22476)

* Adding 'MessageHasBeenDeleted' hook to plugins

* Remove debug logs

* Add unit test

* Bumping the required version

* Fix CI problems

* Increasing the minimum version

* go fmt

---------

Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
Co-authored-by: Mattermost Build <build@mattermost.com>
Этот коммит содержится в:
Jesús Espino
2023-09-14 18:33:22 +02:00
коммит произвёл GitHub
родитель c731630e88
Коммит 17ff2049ec
7 изменённых файлов: 128 добавлений и 0 удалений

Просмотреть файл

@@ -113,6 +113,12 @@ func (hooks *hooksTimerLayer) MessageHasBeenUpdated(c *Context, newPost, oldPost
hooks.recordTime(startTime, "MessageHasBeenUpdated", true)
}
func (hooks *hooksTimerLayer) MessageHasBeenDeleted(c *Context, post *model.Post) {
startTime := timePkg.Now()
hooks.hooksImpl.MessageHasBeenDeleted(c, post)
hooks.recordTime(startTime, "MessageHasBeenDeleted", true)
}
func (hooks *hooksTimerLayer) ChannelHasBeenCreated(c *Context, channel *model.Channel) {
startTime := timePkg.Now()
hooks.hooksImpl.ChannelHasBeenCreated(c, channel)