Renamed type to type_ to conform with naming conventions