MySQL: Outgoing booleans are turned into ints
MySQL: Outgoing booleans are turned into ints

In the MySQL dialect, values used to generate insert, bulk insert, and update queries are now checked for boolean-ness and will be turned into an int.

There was already duplicated logic applied to outgoing values to check if the value was a Date or not. I factored out value processing to a single function and added a check for typeof boolean.

The new function also escapes the return value since that was also being done everywhere.

Fixes #607

IrfanBaqui/sequelize