Skip to content

Commit

Permalink
feat: migrate to # in message label
Browse files Browse the repository at this point in the history
  • Loading branch information
OldTyT committed Aug 11, 2024
1 parent b8a217c commit 08fb1b3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions internal/frigate/frigate.go
Original file line number Diff line number Diff line change
Expand Up @@ -204,8 +204,8 @@ func SendMessageEvent(FrigateEvent EventStruct, bot *tgbotapi.BotAPI) {

// Prepare text message
text := "*Event*\n"
text += "┣*Camera*\n`" + FrigateEvent.Camera + "`\n"
text += "┣*Label*\n`" + FrigateEvent.Label + "`\n"
text += "┣*Camera*\n#" + FrigateEvent.Camera + "\n"
text += "┣*Label*\n#" + FrigateEvent.Label + "\n"
t_start := time.Unix(int64(FrigateEvent.StartTime), 0)
text += fmt.Sprintf("┣*Start time*\n┗ `%s", t_start) + "`\n"
if FrigateEvent.EndTime == 0 {
Expand All @@ -216,7 +216,7 @@ func SendMessageEvent(FrigateEvent EventStruct, bot *tgbotapi.BotAPI) {
}
text += fmt.Sprintf("┣*Top score*\n┗ `%f", (FrigateEvent.Data.TopScore*100)) + "%`\n"
text += "┣*Event id*\n┗ `" + FrigateEvent.ID + "`\n"
text += "┣*Zones*\n`" + strings.Join(GETZones(FrigateEvent.Zones), ", ") + "`\n"
text += "┣*Zones*\n#" + strings.Join(GETZones(FrigateEvent.Zones), ", #") + "\n"
text += "*URLs*\n"
text += "┣[Events](" + conf.FrigateExternalURL + "/events?cameras=" + FrigateEvent.Camera + "&labels=" + FrigateEvent.Label + "&zones=" + strings.Join(GETZones(FrigateEvent.Zones), ",") + ")\n"
text += "┣[General](" + conf.FrigateExternalURL + ")\n"
Expand Down

0 comments on commit 08fb1b3

Please sign in to comment.