Skip to content

Commit 9741c5a

Browse files
authored
Merge pull request #33 from dmarkham/sql-typeo
typeo in the template var
2 parents 3100ad1 + 017d714 commit 9741c5a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

golden_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -1685,7 +1685,7 @@ func (i *Prime) Scan(value interface{}) error {
16851685
var str string
16861686
switch v := value.(type) {
16871687
case []byte:
1688-
str = string(b)
1688+
str = string(v)
16891689
case string:
16901690
str = v
16911691
case fmt.Stringer:
@@ -1872,7 +1872,7 @@ func (i *Prime) Scan(value interface{}) error {
18721872
var str string
18731873
switch v := value.(type) {
18741874
case []byte:
1875-
str = string(b)
1875+
str = string(v)
18761876
case string:
18771877
str = v
18781878
case fmt.Stringer:

sql.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const scanMethod = `func (i *%[1]s) Scan(value interface{}) error {
1515
var str string
1616
switch v := value.(type) {
1717
case []byte:
18-
str = string(b)
18+
str = string(v)
1919
case string:
2020
str = v
2121
case fmt.Stringer:

0 commit comments

Comments
 (0)