From 82e1a2c90411bb53ae83cb9bb3b6906bc24654d7 Mon Sep 17 00:00:00 2001 From: Baipyrus Date: Fri, 12 Apr 2024 13:59:15 +0200 Subject: [PATCH] better more robust typing --- main.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/main.go b/main.go index 244ca72..01e425a 100644 --- a/main.go +++ b/main.go @@ -31,17 +31,17 @@ type Update struct { } type Color struct { - R int `json:"r"` - G int `json:"g"` - B int `json:"b"` + R uint8 `json:"r"` + G uint8 `json:"g"` + B uint8 `json:"b"` Endpoint Endpoint `json:"endpoint"` } type Rectangle struct { X int `json:"x"` Y int `json:"y"` - W int `json:"w"` - H int `json:"h"` + W uint `json:"w"` + H uint `json:"h"` Endpoint Endpoint `json:"endpoint"` }