1
0
mirror of https://github.com/ManyakRus/starter.git synced 2025-11-23 22:45:11 +02:00

сделал defer stopapp.GetWaitGroup_Main().Done()

This commit is contained in:
Nikitin Aleksandr
2025-05-15 14:08:51 +03:00
parent 18ee0e3d6b
commit 6bb95b522c
22 changed files with 40 additions and 33 deletions

View File

@@ -257,6 +257,7 @@ func ForwardMessage(msg *imap.Message, email_send_to string) error {
// WaitStop - ожидает отмену глобального контекста
func WaitStop() {
defer stopapp.GetWaitGroup_Main().Done()
select {
case <-contextmain.GetContext().Done():
@@ -268,7 +269,6 @@ func WaitStop() {
//
CloseConnection()
stopapp.GetWaitGroup_Main().Done()
}
// Start - необходимые процедуры для подключения к серверу email imap