remove query string from apple dev doc urls
parent
6be7fee1ad
commit
dd46072666
|
@ -2,11 +2,15 @@ module.exports = {
|
||||||
|
|
||||||
dev_doc_url: function (url) {
|
dev_doc_url: function (url) {
|
||||||
|
|
||||||
if (url.endsWith('/')) {
|
let query_parts = url.split('?');
|
||||||
url = url.slice(0, -1)
|
|
||||||
|
let queryless = query_parts[0];
|
||||||
|
|
||||||
|
if (queryless.endsWith('/')) {
|
||||||
|
queryless = queryless.slice(0, -1)
|
||||||
}
|
}
|
||||||
|
|
||||||
let parts = url.split("/");
|
let parts = queryless.split("/");
|
||||||
|
|
||||||
let json_url = "https://developer.apple.com/tutorials/data";
|
let json_url = "https://developer.apple.com/tutorials/data";
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue