mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-22 14:55:16 +00:00
show bbgo version name
This commit is contained in:
parent
b60fd9e356
commit
e8205556ff
|
@ -3,6 +3,7 @@ package telegramnotifier
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
|
"github.com/c9s/bbgo/pkg/version"
|
||||||
"github.com/pquerna/otp"
|
"github.com/pquerna/otp"
|
||||||
"github.com/pquerna/otp/totp"
|
"github.com/pquerna/otp/totp"
|
||||||
"github.com/sirupsen/logrus"
|
"github.com/sirupsen/logrus"
|
||||||
|
@ -148,7 +149,10 @@ func (it *Interaction) Start(session Session) {
|
||||||
it.session = &session
|
it.session = &session
|
||||||
|
|
||||||
if it.session.Owner != nil && it.session.Chat != nil {
|
if it.session.Owner != nil && it.session.Chat != nil {
|
||||||
if _, err := it.bot.Send(it.session.Chat, fmt.Sprintf("Hi %s, I'm back", it.session.Owner.Username)); err != nil {
|
if _, err := it.bot.Send(it.session.Chat, fmt.Sprintf("Hi %s, I'm back, this is version %s",
|
||||||
|
it.session.Owner.Username,
|
||||||
|
version.Version,
|
||||||
|
)); err != nil {
|
||||||
log.WithError(err).Error("failed to send telegram message")
|
log.WithError(err).Error("failed to send telegram message")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user