Skip to content

Commit

Permalink
lints
Browse files Browse the repository at this point in the history
  • Loading branch information
serprex committed Dec 6, 2024
1 parent af607e9 commit 2fd1e5d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion flow/model/qrecord_copy_from_source.go
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ func (src *QRecordCopyFromSource) Values() ([]interface{}, error) {
case qvalue.QValueTimestampTZ:
values[i] = pgtype.Timestamptz{Time: v.Val, Valid: true}
case qvalue.QValueUUID:
values[i] = uuid.UUID(v.Val)
values[i] = v.Val
case qvalue.QValueArrayUUID:
a, err := constructArray[uuid.UUID](qValue, "ArrayUUID")
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion flow/model/qvalue/qvalue.go
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ func (v QValueUUID) Value() any {
}

func (v QValueUUID) LValue(ls *lua.LState) lua.LValue {
return shared.LuaUuid.New(ls, uuid.UUID(v.Val))
return shared.LuaUuid.New(ls, v.Val)
}

type QValueArrayUUID struct {
Expand Down
4 changes: 1 addition & 3 deletions flow/model/record_items.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ import (
"fmt"
"math"

"github.com/google/uuid"

"github.com/PeerDB-io/peer-flow/datatypes"
"github.com/PeerDB-io/peer-flow/model/qvalue"
)
Expand Down Expand Up @@ -89,7 +87,7 @@ func (r RecordItems) toMap(opts ToJSONOptions) (map[string]interface{}, error) {

switch v := qv.(type) {
case qvalue.QValueUUID:
jsonStruct[col] = uuid.UUID(v.Val)
jsonStruct[col] = v.Val
case qvalue.QValueQChar:
jsonStruct[col] = string(v.Val)
case qvalue.QValueString:
Expand Down

0 comments on commit 2fd1e5d

Please sign in to comment.