Skip to content

Commit

Permalink
PR feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
Hydrocharged committed Jan 16, 2024
1 parent 20dd5f5 commit 3b08b98
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions server/functions/left.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ package functions
// left represents the PostgreSQL function of the same name.
var left = Function{
Name: "left",
Overloads: []interface{}{left_string},
Overloads: []interface{}{left_string_int},
}

// left_string is one of the overloads of left.
func left_string(string StringType, n IntegerType) (StringType, error) {
func left_string_int(string StringType, n IntegerType) (StringType, error) {
if string.IsNull || n.IsNull {
return StringType{IsNull: true}, nil
}
Expand Down
4 changes: 2 additions & 2 deletions server/functions/right.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ package functions
// right represents the PostgreSQL function of the same name.
var right = Function{
Name: "right",
Overloads: []interface{}{right_string},
Overloads: []interface{}{right_string_int},
}

// right_string is one of the overloads of right.
func right_string(string StringType, n IntegerType) (StringType, error) {
func right_string_int(string StringType, n IntegerType) (StringType, error) {
if string.IsNull || n.IsNull {
return StringType{IsNull: true}, nil
}
Expand Down
4 changes: 2 additions & 2 deletions server/functions/split_part.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,11 @@ import (
// split_part represents the PostgreSQL function of the same name.
var split_part = Function{
Name: "split_part",
Overloads: []interface{}{split_part_string},
Overloads: []interface{}{split_part_string_string_int},
}

// split_part_string is one of the overloads of split_part.
func split_part_string(str StringType, delimiter StringType, n IntegerType) (StringType, error) {
func split_part_string_string_int(str StringType, delimiter StringType, n IntegerType) (StringType, error) {
if str.IsNull || delimiter.IsNull || n.IsNull {
return StringType{IsNull: true}, nil
}
Expand Down

0 comments on commit 3b08b98

Please sign in to comment.