Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filtering on magazine tags on the /no/magasin page goes to Norwegian … #2727

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
4 changes: 1 addition & 3 deletions web/templates/magazine/Magazineroom.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,7 @@ const MagazineRoom = ({ pageData, slug }: MagazineIndexTemplateProps) => {
const resultsRef = useRef<HTMLDivElement>(null)
const [isLoading, setIsLoading] = useState(false)
const router = useRouter()
const parentSlug =
(router.locale !== router.defaultLocale ? `/${router.locale}` : '') +
router.asPath.substring(router.asPath.indexOf('/'), router.asPath.lastIndexOf('/'))
const parentSlug = `${router.locale !== router.defaultLocale ? `/${router.locale}` : ''}${router.pathname}`

const magazineList = useMemo(() => magazineArticles, [magazineArticles])
const pagedList = useMemo(() => chunkArray(magazineList, 12), [magazineList])
Expand Down
Loading