We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 238f413 commit 46ee805Copy full SHA for 46ee805
src/CommunityToolkit.Maui.MediaElement/Views/MauiMediaElement.macios.cs
@@ -170,7 +170,7 @@ static bool TryGetCurrentPage([NotNullWhen(true)] out Page? currentPage)
170
}
171
172
// If not using Shell or a Modal Page, return the visible page in the (non-modal) NavigationStack
173
- if (window.Navigation.NavigationStack[^1] is Page page)
+ if (window.Navigation.NavigationStack.LastOrDefault() is Page page)
174
{
175
currentPage = page;
176
return true;
0 commit comments