ezimuel / zend-expressive-api

Web API skeleton using zend-expressive
59 stars 30 forks source link

Cast return value of addUser #5

Closed Rockstar04 closed 6 years ago

Rockstar04 commented 6 years ago

ZendDB does not enforce return types, so we need to handle possibility of strings.

ZendDB's AbstractTableGateway.php does not declare its return type (other than in its docBlock), but UserModel.php sets a return type of int with no validation or guarantee that that the table gateway has actually returned an int.

https://github.com/ezimuel/zend-expressive-api/pull/3#issuecomment-388360022

ezimuel commented 6 years ago

Thanks @Rockstar04!