diff --git a/src/Generator/Type/Go.php b/src/Generator/Type/Go.php index 303a2732..12512259 100644 --- a/src/Generator/Type/Go.php +++ b/src/Generator/Type/Go.php @@ -48,16 +48,6 @@ protected function getString(): string return 'string'; } - protected function getStringFormat(Format $format): string - { - return match ($format) { - Format::DATE => 'time.Time', - Format::DATETIME => 'time.Time', - Format::TIME => 'time.Time', - default => $this->getString(), - }; - } - protected function getInteger(): string { return 'int'; diff --git a/tests/Generator/resource/go/go.go b/tests/Generator/resource/go/go.go index 1b3f655b..7169220a 100644 --- a/tests/Generator/resource/go/go.go +++ b/tests/Generator/resource/go/go.go @@ -38,8 +38,8 @@ type News struct { Source any `json:"source"` Author *Author `json:"author"` Meta *Meta `json:"meta"` - SendDate time.Time `json:"sendDate"` - ReadDate time.Time `json:"readDate"` + SendDate string `json:"sendDate"` + ReadDate string `json:"readDate"` Expires string `json:"expires"` Range string `json:"range"` Price float64 `json:"price"` @@ -47,7 +47,7 @@ type News struct { Content string `json:"content"` Question string `json:"question"` Version string `json:"version"` - CoffeeTime time.Time `json:"coffeeTime"` + CoffeeTime string `json:"coffeeTime"` ProfileUri string `json:"profileUri"` Captcha string `json:"g-recaptcha-response"` MediaFields string `json:"media.fields"`