Skip to content

Commit bac505e

Browse files
lixingwangFrank Martinez
authored and
Frank Martinez
committed
fix typo
1 parent c6d04a2 commit bac505e

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

Diff for: function/datetime/current.go

+6-6
Original file line numberDiff line numberDiff line change
@@ -9,26 +9,26 @@ import (
99
)
1010

1111

12-
type curremtFn struct {
12+
type currentFn struct {
1313
}
1414

1515
func init() {
16-
function.Register(&curremtFn{})
16+
function.Register(&currentFn{})
1717
}
1818

19-
func (s *curremtFn) Name() string {
19+
func (s *currentFn) Name() string {
2020
return "current"
2121
}
2222

23-
func (s *curremtFn) GetCategory() string {
23+
func (s *currentFn) GetCategory() string {
2424
return "datetime"
2525
}
2626

27-
func (s *curremtFn) Sig() (paramTypes []data.Type, isVariadic bool) {
27+
func (s *currentFn) Sig() (paramTypes []data.Type, isVariadic bool) {
2828
return []data.Type{}, false
2929
}
3030

31-
func (s *curremtFn) Eval(d ...interface{}) (interface{}, error) {
31+
func (s *currentFn) Eval(d ...interface{}) (interface{}, error) {
3232
log.RootLogger().Debugf("Returns the current datetime with UTC timezone")
3333
return time.Now().UTC(), nil
3434
}

Diff for: function/datetime/current_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ func init() {
1313
}
1414

1515
func TestCurrentDate_Eval(t *testing.T) {
16-
n := CurrentDatetime{}
16+
n := currentFn{}
1717
datetime, _ := n.Eval(nil)
1818
fmt.Println(datetime)
1919
assert.NotNil(t, datetime)

0 commit comments

Comments
 (0)