Codu quality patch in order to get merged with master
the build was successful Details

This commit is contained in:
Amalvy Arthur 2018-12-31 16:50:19 +01:00
parent 29add0224c
commit db421c828b
4 changed files with 4 additions and 6 deletions

View File

@ -67,7 +67,6 @@ func main() {
b.Handle(key, value)
}
log.Println("token : " + settings.Settings["token"].(string))
log.Println("Starting bot")
b.Start()
}

View File

@ -1 +0,0 @@
aethor@pc60.home.13981:1546264820

View File

@ -70,7 +70,7 @@ func Unsubscribe(m *tb.Message) {
shared.Users.Set(m.Sender.Username, "subscribed_chats", strings.Join(splittedChats, ":"))
}
// List all subscribers of the current chat
// ListSubscribers List all subscribers of the current chat
// Command syntax : /listsubscribers
func ListSubscribers(m *tb.Message) {
if m.Chat.Type != "group" && m.Chat.Type != "supergroup" {
@ -104,7 +104,7 @@ func Publish(m *tb.Message) {
}
// Remove a message from published messages in the current chat
// Unpublish remove a message from published messages in the current chat
// Command syntax : /unpublish [publication ID]
func Unpublish(m *tb.Message) {
parsedCommand := strings.Split(m.Text, " ")
@ -131,7 +131,7 @@ func Unpublish(m *tb.Message) {
shared.Bot.Send(m.Chat, "Message supprimé des publication")
}
// If performed in MP : retrieve all messages from all subscribed sources for the user
// Retrieve If performed in MP : retrieve all messages from all subscribed sources for the user
// If performed in Group Chat : retrieved all published messages for this chat
// Command syntax : /retrieve
func Retrieve(m *tb.Message) {

View File

@ -61,7 +61,7 @@ func (u users) Set(username string, key, data string) {
go uf.write()
}
// Get all known usernames
// GetUsernames all usernames stored in settings
func (u users) GetUsernames() []string {
u.mutex.Lock()
defer u.mutex.Unlock()