params is undefined, did you mean opts?