recently i decided to take a look at the context package and i feel i get the hang of it. However, in a video i saw this odd looking line of code, partly i understood it but not the last bit.
I did not include the entire code of that vidoe because i feel like its irrelevant. My question however is, what this this mean: ".(*log.Entry)". Thanks for replies, i have seen this in multiple examples but it is never explained, is it converting log which i believe is an interface{}, to *log.Entry?
func index(w http.ResponseWriter, r *http.Request {
log, ok := r.Context().Value(logger).(*log.Entry)
...
...
}