ctxdata icon indicating copy to clipboard operation
ctxdata copied to clipboard

minor: GetAllMap method docstring is incorrect

Open erraggy opened this issue 4 years ago • 2 comments

https://github.com/peterbourgon/ctxdata/blob/503d7993117f2a5e17d15720b54f47a80c06a9d1/data.go#L121-L122

This method returns only a single map[string]interface{} value but the current docstring states that: If this method is called on a nil Data pointer, it returns ErrNoData.

It should instead read: If this method is called on a nil Data pointer, it returns an empty map.

erraggy avatar Apr 23 '21 23:04 erraggy

Oops!

peterbourgon avatar Apr 26 '21 13:04 peterbourgon

GetAllSlice too!

peterbourgon avatar Apr 26 '21 13:04 peterbourgon