break: update ServerMessage model

- rename MaxSession to TotalSession (and JSON struct tags)

🤖
This commit is contained in:
Sebastian Mark 2024-10-20 23:20:23 +02:00
parent 314e71acba
commit f9b2a76894
5 changed files with 23 additions and 23 deletions

View file

@ -2,8 +2,8 @@ package models
// ServerMessage represents the data sent to the client via WebSocket.
type ServerMessage struct {
Mode string `json:"mode"` // "Work", "ShortBreak", or "LongBreak"
Session int `json:"session"` // Current session number
MaxSession int `json:"max_session"` // Total number of sessions
TimeLeft int `json:"time_left"` // Remaining time in seconds
Mode string `json:"mode"` // "Work", "ShortBreak", or "LongBreak"
Session int `json:"session"` // Current session number
TotalSession int `json:"total_sessions"` // Total number of sessions
TimeLeft int `json:"time_left"` // Remaining time in seconds
}