/**
* Modifies the original insert query to append a "RETURNING *" epilogue
* so that the latest insert id can be retrieved
*
* @param \Cake\Database\Query $query The query to translate.
* @return \Cake\Database\Query
*/
protected function _insertQueryTranslator($query)
{
if (!$query->clause('epilog')) {
$query->epilog('RETURNING *');
}
return $query;
}