Skip to content
This repository was archived by the owner on Nov 8, 2022. It is now read-only.

Commit 3fd64d3

Browse files
committed
fix(router): remove getSubPath function
1 parent 8643688 commit 3fd64d3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pages/communities.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@ import R from 'ramda'
77

88
import { ROUTE } from '@constant'
99
import {
10+
parseURL,
1011
getJwtToken,
1112
makeGQClient,
1213
queryStringToJSON,
1314
nilOrEmpty,
14-
getSubPath,
1515
ssrAmbulance,
1616
parseTheme,
1717
} from '@utils'
@@ -45,7 +45,7 @@ async function fetchData(props, opt) {
4545
const token = realname ? getJwtToken(props) : null
4646
const gqClient = makeGQClient(token)
4747
const userHasLogin = nilOrEmpty(token) === false
48-
const subPath = getSubPath(props)
48+
const { subPath } = parseURL(props)
4949
const category = subPath !== '' ? subPath : 'pl'
5050

5151
const { asPath } = props

0 commit comments

Comments
 (0)