Somehow, at runtime, I am getting the following panic message, even if it appears to me the method is properly defined to the struct that implements that interface.
panic: interface conversion: schema.MerchantResultset
is not search.ResultsetInterface: missing method Add
This is the interface blueprint
type ResultsetInterface interface {
Init(string)
CacheSet(context.Context) error
CacheSetPart(context.Context, int) error
CacheGet(context.Context, string) error
Add(interface{})
AddResultset(interface{})
}
The following is the method that is reported missing during runtime, which is assigned to my struct MerchantResultset.
func (mr *MerchantResultset) Add(item interface{}) {
mr.Data = append(mr.Data, item.(Merchant))
}
I am somehow very puzzled trying to understand what is actually being needed here