nowinandroid icon indicating copy to clipboard operation
nowinandroid copied to clipboard

Avoid popUpTo and navigateTo same route

Open anhtuannd opened this issue 1 year ago • 3 comments

Fix for #1463, #1465 and #1597

The issue arises when both popUpTo() and navigate() target the same route. This can lead to unexpected behavior in navigation within NIA.

If start destination and target destination are same, we can just set saveState and restoreState to false.

anhtuannd avatar May 24 '24 15:05 anhtuannd

@dturner This PR is ready for review

anhtuannd avatar Jul 07 '24 14:07 anhtuannd

Rebased to latest type-safe navigation

anhtuannd avatar Sep 10 '24 16:09 anhtuannd

Also fixes https://github.com/android/nowinandroid/issues/1597

anhtuannd avatar Sep 11 '24 09:09 anhtuannd

Thanks for this PR. Once you have addressed the comments and CI passes, I'd like to see this merged into main.

keyboardsurfer avatar Dec 11 '24 10:12 keyboardsurfer

This is no longer needed after we migrate to type-safe navigation.

anhtuannd avatar Jan 09 '25 14:01 anhtuannd