Skip to content

Commit

Permalink
Fixed a logging error that was printing message contents to the console.
Browse files Browse the repository at this point in the history
  • Loading branch information
seansackowitz committed Jun 26, 2018
1 parent 12341e5 commit 0b02c7d
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
2 changes: 1 addition & 1 deletion plugin.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"id": "mattermost-gyazo",
"name": "Gyazo",
"description": "Format messages with gyazo links.",
"version": "0.1.0",
"version": "0.1.1",
"backend": {
"executable": "server/plugin.exe"
},
Expand Down
3 changes: 0 additions & 3 deletions server/plugin.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import (
"sync/atomic"
"time"

"github.com/mattermost/mattermost-server/mlog"
"github.com/mattermost/mattermost-server/model"
"github.com/mattermost/mattermost-server/plugin"
)
Expand Down Expand Up @@ -73,13 +72,11 @@ func (p *Plugin) FormatPost(post *model.Post, gyazo string) *model.Post {
}
post.Message = "[Gyazo](" + gyazo + ")\n" + url

mlog.Error(post.Message)
return post
}

// MessageWillBePosted is invoked when a message is posted by a user before it is commited
// to the database.
func (p *Plugin) MessageWillBePosted(post *model.Post) (*model.Post, string) {
mlog.Error(post.Message)
return p.FilterPost(post)
}

0 comments on commit 0b02c7d

Please sign in to comment.