fix the filling constructor