Bugg fix with lastInsertId.