Skip to content

Commit 723540c

Browse files
ci: apply automated fixes
1 parent 983b7ce commit 723540c

File tree

4 files changed

+9
-13
lines changed

4 files changed

+9
-13
lines changed

packages/react-router/src/link.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ export function useLinkProps<
221221
options.replace,
222222
options.resetScroll,
223223
options.viewTransition,
224-
getFrom
224+
getFrom,
225225
],
226226
)
227227

packages/react-router/tests/link.test.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5955,9 +5955,7 @@ describe('relative links to from route', () => {
59555955
expect(
59565956
await screen.findByTestId('posts-index-heading'),
59575957
).toBeInTheDocument()
5958-
expect(
5959-
screen.queryByTestId('post-notes-heading'),
5960-
).not.toBeInTheDocument()
5958+
expect(screen.queryByTestId('post-notes-heading')).not.toBeInTheDocument()
59615959
expect(
59625960
screen.queryByTestId('post-detail-index-heading'),
59635961
).not.toBeInTheDocument()

packages/react-router/tests/useNavigate.test.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2111,9 +2111,7 @@ describe('relative navigate to from route', () => {
21112111
expect(
21122112
await screen.findByTestId('posts-index-heading'),
21132113
).toBeInTheDocument()
2114-
expect(
2115-
screen.queryByTestId('post-notes-heading'),
2116-
).not.toBeInTheDocument()
2114+
expect(screen.queryByTestId('post-notes-heading')).not.toBeInTheDocument()
21172115
expect(
21182116
screen.queryByTestId('post-detail-index-heading'),
21192117
).not.toBeInTheDocument()

packages/router-core/src/router.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1430,13 +1430,13 @@ export class RouterCore<
14301430
undefined,
14311431
).matchedRoutes
14321432

1433-
const matchedFrom = findLast(allCurrentLocationMatches, (d) => {
1434-
return comparePaths(d.fullPath, dest.from!)
1435-
})
1433+
const matchedFrom = findLast(allCurrentLocationMatches, (d) => {
1434+
return comparePaths(d.fullPath, dest.from!)
1435+
})
14361436

1437-
const matchedCurrent = findLast(allFromMatches, (d) => {
1438-
return comparePaths(d.fullPath, lastMatch.fullPath)
1439-
})
1437+
const matchedCurrent = findLast(allFromMatches, (d) => {
1438+
return comparePaths(d.fullPath, lastMatch.fullPath)
1439+
})
14401440

14411441
// for from to be invalid it shouldn't just be unmatched to currentLocation
14421442
// but the currentLocation should also be unmatched to from

0 commit comments

Comments
 (0)