summaryrefslogtreecommitdiff
path: root/doCountAuto.go
blob: 00d4b585c1c77ef60ac6a8afea42ba6a909b2749 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
package main

import (
	"fmt"
	"strings"
)

func doCountAuto() {
	if err := me.chats.ConfigLoad(); err != nil {
		badExit(err)
	}
	count := 0
	for _, chat := range me.chats.GetChats() {
		if strings.HasPrefix(chat.GetChatName(), "Auto ") {
			count++
		}
	}
	fmt.Println(count)
}