Skip to content

Commit 36435e0

Browse files
author
gbbr
committed
Return what constructor indicatesg
1 parent 215e896 commit 36435e0

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎chapter7/patterns/search/searchers.go‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ func init() {
1919
type Google struct{}
2020

2121
// NewGoogle returns a Google Searcher value.
22-
func NewGoogle() Searcher {
22+
func NewGoogle() Google {
2323
return Google{}
2424
}
2525

@@ -55,7 +55,7 @@ func (g Google) Search(searchTerm string, searchResults chan<- []Result) {
5555
type Bing struct{}
5656

5757
// NewBing returns a Bing Searcher value.
58-
func NewBing() Searcher {
58+
func NewBing() Bing {
5959
return Bing{}
6060
}
6161

@@ -91,7 +91,7 @@ func (b Bing) Search(searchTerm string, searchResults chan<- []Result) {
9191
type Yahoo struct{}
9292

9393
// NewYahoo returns a Yahoo Searcher value.
94-
func NewYahoo() Searcher {
94+
func NewYahoo() Yahoo {
9595
return Yahoo{}
9696
}
9797

0 commit comments

Comments
 (0)