10000 fix: proper nullable types · barrownicholas/postgres-meta@b111288 · GitHub
[go: up one dir, main page]

Skip to content

Commit b111288

Browse files
fix: proper nullable types
1 parent b85bf01 commit b111288

File tree

1 file changed

+7
-7
lines changed
  • src/server/templates

1 file changed

+7
-7
lines changed

src/server/templates/go.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -275,13 +275,13 @@ const GO_TYPE_MAP = {
275275
type GoType = (typeof GO_TYPE_MAP)[keyof typeof GO_TYPE_MAP]
276276

277277
const GO_NULLABLE_TYPE_MAP: Record<GoType, string> = {
278-
string: 'sql.NullString',
279-
bool: 'sql.NullBool',
280-
int16: 'sql.NullInt32',
281-
int32: 'sql.NullInt32',
282-
int64: 'sql.NullInt64',
283-
float32: 'sql.NullFloat64',
284-
float64: 'sql.NullFloat64',
278+
string: '*string',
279+
bool: '*bool',
280+
int16: '*int16',
281+
int32: '*int32',
282+
int64: '*int64',
283+
float32: '*float32',
284+
float64: '*float64',
285285
'[]byte': '[]byte',
286286
'interface{}': 'interface{}',
287287
'map[string]interface{}': 'map[string]interface{}',

0 commit comments

Comments
 (0)
0