Skip to content

Commit cf0e410

Browse files
james4etmrts
authored andcommitted
creational/singleton: fix dereferencing
1 parent 5895317 commit cf0e410

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

creational/singleton.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ type singleton map[string]string
1111

1212
var once sync.Once
1313

14-
var instance *singleton
14+
var instance singleton
1515

16-
func New() *singleton {
16+
func New() singleton {
1717
once.Do(func() {
1818
instance = make(singleton)
1919
})

0 commit comments

Comments
 (0)