constructor takes both $rows and $data optional params
fix gh-16