Forward irc errors to the client, improve command validation and feedback, handle topic changes

This commit is contained in:
Ken-Håvard Lieng 2017-05-28 07:20:43 +02:00
parent 993d29242e
commit aa59e71745
17 changed files with 328 additions and 96 deletions

View file

@ -61,11 +61,12 @@ type Quit struct {
}
type Message struct {
ID string `json:"id"`
Server string `json:"server"`
ID string `json:"id,omitempty"`
Server string `json:"server,omitempty"`
From string `json:"from,omitempty"`
To string `json:"to,omitempty"`
Content string `json:"content"`
Type string `json:"type,omitempty"`
}
type Messages struct {
@ -79,7 +80,8 @@ type Messages struct {
type Topic struct {
Server string `json:"server"`
Channel string `json:"channel"`
Topic string `json:"topic"`
Topic string `json:"topic,omitempty"`
Nick string `json:"nick,omitempty"`
}
type Userlist struct {