MapMe
MapMe copied to clipboard
`attach` now accepts a nullable `View` as it internally is used safely
The mapView
is treated as Nullable
throughout MapMeAdapter
but when attaching, only a NonNull View
is accepted. Even as SupportMapFragment
is inflated in a parent's onCreateView
, upon configuration changes onMapReady
might be called before onCreateView
of the parent so if the attaching is done in onMapReady
the only possible valid View
to pass is the one fetched by requireView()
but that View
has yet not been created and an IllegalException
will be thrown.
Instead if getView()
that is Nullable
would be allowed, things would work out.