Skip to content

Commit

Permalink
MvxActivityViewExtensions: use direct cast instead of "as"
Browse files Browse the repository at this point in the history
  • Loading branch information
nmilcoff committed Aug 20, 2017
1 parent 39f0bd3 commit 85fe7e6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion MvvmCross/Droid/Droid/Views/MvxActivityViewExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public static void OnViewCreate(this IMvxAndroidView androidView, Bundle bundle)
var cache = Mvx.Resolve<IMvxSingleViewModelCache>();
var cached = cache.GetAndClear(bundle);

var view = androidView as IMvxView;
var view = (IMvxView)androidView;
var savedState = GetSavedStateFromBundle(bundle);
view.OnViewCreate(() => cached ?? androidView.LoadViewModel(savedState));
}
Expand Down

0 comments on commit 85fe7e6

Please sign in to comment.