protected void onCreate(@Nullable Bundle savedInstanceState) {
mFragments.attachHost(null /*parent*/);
super.onCreate(savedInstanceState);
NonConfigurationInstances nc =
(NonConfigurationInstances) getLastNonConfigurationInstance();
if (nc != null) {
mViewModelStore = nc.viewModelStore; //HERE IS THE ISSUE
}
I found in Android code why the ViewModelProvider should be called after the super.onCreate
the mViewModelStore is the issue
it is com.sun so it should be avoided if possible :D
Yeap