mirror of
https://github.com/mmjee/Piped-Material.git
synced 2024-12-06 19:26:36 +01:00
Handle the new /@<channel ID> URLs
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
<template>
|
||||
<v-progress-linear indeterminate />
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'NewChannelRedirect',
|
||||
mounted () {
|
||||
const { channelId } = this.$route.params
|
||||
if (channelId.length === 0) {
|
||||
this.$router.replace('/')
|
||||
}
|
||||
this.$router.replace('/c/@' + channelId)
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -58,6 +58,10 @@ const routes = [
|
||||
name: 'Channel',
|
||||
component: () => import('@/routes/Channel')
|
||||
},
|
||||
{
|
||||
path: '/@:channelId',
|
||||
component: () => import('@/components/NewChannelRedirect')
|
||||
},
|
||||
{
|
||||
path: '/:videoId([a-zA-Z0-9_-]{11})',
|
||||
component: () => import('@/components/Video/VideoRedirect')
|
||||
|
||||
Reference in New Issue
Block a user