shopee-php icon indicating copy to clipboard operation
shopee-php copied to clipboard

add (int) in getDefaultParameters()

Open rmdhfz opened this issue 4 years ago • 2 comments

To get the default parameter, int is required. If not : partner_id and shopid will be strings. That will cause an error

rmdhfz avatar Nov 12 '20 01:11 rmdhfz

Hi @rmdhfz

Thank you for pointing this out.

To avoid property type error. Maybe we should prevent users from setting wrong parameters. When the parameter passed in through the constructor of Client is not a int, throw an exception.

minchao avatar Nov 12 '20 01:11 minchao

You are welcome. Yes, we should prevent users from setting wrong parameters.

rmdhfz avatar Nov 12 '20 02:11 rmdhfz