1
0
mirror of https://github.com/robertkrimen/otto synced 2025-10-19 19:55:30 +08:00

fix(underscore): remove unneeded wrapping lambda (#320)

Use func value instead of wrapping lambda

Found using https://go-critic.github.io/overview.html#unlambda-ref
This commit is contained in:
Iskander (Alex) Sharipov 2021-09-27 18:34:54 +03:00 committed by GitHub
parent 43d26482c3
commit 818f7465f8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -29,9 +29,7 @@ import (
"github.com/robertkrimen/otto/registry"
)
var entry *registry.Entry = registry.Register(func() string {
return Source()
})
var entry *registry.Entry = registry.Register(Source)
// Enable underscore runtime inclusion.
func Enable() {