1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-01-24 21:42:51 -05:00

core/server: refactory to use shared params/request structs

This commit is contained in:
bbedward
2025-12-09 14:13:20 -05:00
parent 993f14a31f
commit 85968ec417
23 changed files with 913 additions and 953 deletions

View File

@@ -29,3 +29,9 @@ func Respond[T any](conn net.Conn, id int, result T) {
resp := Response[T]{ID: id, Result: &result}
json.NewEncoder(conn).Encode(resp)
}
type SuccessResult struct {
Success bool `json:"success"`
Message string `json:"message,omitempty"`
Value string `json:"value,omitempty"`
}