It would be much easier if the params are passed as object