Prevent null pointer exception
This commit is contained in:
parent
e9a147e344
commit
ad0c14e389
1 changed files with 3 additions and 1 deletions
|
@ -125,8 +125,10 @@ public class CryptoNetBalanceViewHolder extends RecyclerView.ViewHolder {
|
|||
preferedCurrencySetting.observe((LifecycleOwner)this.itemView.getContext(), new Observer<GeneralSetting>() {
|
||||
@Override
|
||||
public void onChanged(@Nullable GeneralSetting generalSetting) {
|
||||
if(generalSetting != null){
|
||||
preferredCurrency = generalSetting.getValue();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue