Skip to content

Commit

Permalink
Merge pull request #60 from alingse/patch-1
Browse files Browse the repository at this point in the history
fix pass []any as any in variadic functions
  • Loading branch information
caixw authored Jul 10, 2022
2 parents cf943eb + 3a5da6a commit 8403fbe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/locale/locale.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ func New(key message.Reference, v ...interface{}) *Locale {

// NewError 返回本地化的错误对象
func NewError(key message.Reference, v ...interface{}) error {
return (*Err)(New(key, v))
return (*Err)(New(key, v...))
}

// Translate 功能与 Sprintf 类似,但是可以指定本地化 ID 值。
Expand Down

0 comments on commit 8403fbe

Please sign in to comment.