Skip to content

Commit

Permalink
DRY condition fix
Browse files Browse the repository at this point in the history
  • Loading branch information
superhacker777 committed Oct 13, 2015
1 parent e38f2bd commit faeff79
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion message.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ type Message struct {

// Origin returns an origin of message: group chat / personal.
func (m Message) Origin() User {
if (m.Chat != User{}) {
if m.IsPersonal() {
return m.Chat
}

Expand Down

0 comments on commit faeff79

Please sign in to comment.