diff options
Diffstat (limited to 'Xamarin.Forms.Platform.iOS/Cells')
-rw-r--r-- | Xamarin.Forms.Platform.iOS/Cells/CellRenderer.cs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Xamarin.Forms.Platform.iOS/Cells/CellRenderer.cs b/Xamarin.Forms.Platform.iOS/Cells/CellRenderer.cs index ea0e8d3f..0abf7f80 100644 --- a/Xamarin.Forms.Platform.iOS/Cells/CellRenderer.cs +++ b/Xamarin.Forms.Platform.iOS/Cells/CellRenderer.cs @@ -48,9 +48,9 @@ namespace Xamarin.Forms.Platform.iOS { cell.ForceUpdateSizeRequested -= _onForceUpdateSizeRequested; - _onForceUpdateSizeRequested = (sender, e) => + _onForceUpdateSizeRequested = (sender, e) => { - var index = tableView.IndexPathForCell(nativeCell); + var index = tableView?.IndexPathForCell(nativeCell) ?? (sender as Cell)?.GetIndexPath(); if (index != null) tableView.ReloadRows(new[] { index }, UITableViewRowAnimation.None); }; |