Skip to content

Commit 775b265

Browse files
committed
lint fix
1 parent 8ca5f32 commit 775b265

File tree

2 files changed

+27
-8
lines changed

2 files changed

+27
-8
lines changed

src/common/utils/match-route/index.ts

+6-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,12 @@ const matchRoute = <T extends Route | InvariantRoute>(
4848
updatedBasePath
4949
);
5050
if (matchedRoute) {
51-
matchRouteCache.set(pathname, queryParamObject, updatedBasePath, matchedRoute);
51+
matchRouteCache.set(
52+
pathname,
53+
queryParamObject,
54+
updatedBasePath,
55+
matchedRoute
56+
);
5257

5358
return matchedRoute;
5459
}

src/common/utils/match-route/test.ts

+21-7
Original file line numberDiff line numberDiff line change
@@ -151,15 +151,25 @@ describe('matchRoute()', () => {
151151
).toBeNull();
152152

153153
expect(
154-
// @ts-ignore
155-
matchRoute([routeA, routeB], '/base/abc', DEFAULT_QUERY_PARAMS, basePath)
154+
matchRoute(
155+
// @ts-ignore
156+
[routeA, routeB],
157+
'/base/abc',
158+
DEFAULT_QUERY_PARAMS,
159+
basePath
160+
)
156161
).toMatchObject({
157162
route: routeA,
158163
});
159164

160165
expect(
161-
// @ts-ignore
162-
matchRoute([routeB, routeA], '/base/def', DEFAULT_QUERY_PARAMS, basePath)
166+
matchRoute(
167+
// @ts-ignore
168+
[routeB, routeA],
169+
'/base/def',
170+
DEFAULT_QUERY_PARAMS,
171+
basePath
172+
)
163173
).toMatchObject({
164174
route: routeB,
165175
});
@@ -207,12 +217,16 @@ describe('matchRoute()', () => {
207217
});
208218

209219
expect(
210-
// @ts-ignore
211-
matchRoute([routeA, routeC, routeB], '/base/abc', DEFAULT_QUERY_PARAMS, basePath)
220+
matchRoute(
221+
// @ts-ignore
222+
[routeA, routeC, routeB],
223+
'/base/abc',
224+
DEFAULT_QUERY_PARAMS,
225+
basePath
226+
)
212227
).toMatchObject({
213228
route: routeC,
214229
});
215-
216230
});
217231
});
218232

0 commit comments

Comments
 (0)