mirror of
https://github.com/TeamPiped/Piped.git
synced 2024-08-14 23:57:27 +00:00
Merge pull request #2190 from Bnyro/channel-handles
Support for YouTube handles
This commit is contained in:
commit
4447f203c8
2 changed files with 8 additions and 1 deletions
|
@ -121,7 +121,9 @@ export default {
|
|||
});
|
||||
},
|
||||
async fetchChannel() {
|
||||
const url = this.apiUrl() + "/" + this.$route.params.path + "/" + this.$route.params.channelId;
|
||||
const url = this.$route.path.includes("@")
|
||||
? this.apiUrl() + "/c/" + this.$route.params.channelId
|
||||
: this.apiUrl() + "/" + this.$route.params.path + "/" + this.$route.params.channelId;
|
||||
return await this.fetchJson(url);
|
||||
},
|
||||
async getChannelData() {
|
||||
|
|
|
@ -41,6 +41,11 @@ const routes = [
|
|||
name: "Channel",
|
||||
component: () => import("../components/ChannelPage.vue"),
|
||||
},
|
||||
{
|
||||
path: "/@:channelId",
|
||||
name: "Channel handle",
|
||||
component: () => import("../components/ChannelPage.vue"),
|
||||
},
|
||||
{
|
||||
path: "/login",
|
||||
name: "Login",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue