mirror of
https://github.com/TeamPiped/Piped.git
synced 2024-08-14 23:57:27 +00:00
Handle parameters with mixin.
This commit is contained in:
parent
3b0f1a7678
commit
d76781847b
1 changed files with 3 additions and 5 deletions
|
@ -34,11 +34,9 @@ export default {
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async fetchTrending(region) {
|
async fetchTrending(region) {
|
||||||
let url = Constants.BASE_URL + "/trending";
|
return await this.fetchJson(Constants.BASE_URL + "/trending", {
|
||||||
if (region) {
|
region: region || "US",
|
||||||
url += "?region=" + region;
|
});
|
||||||
}
|
|
||||||
return await this.fetchJson(url);
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue