http -> https for SoundCloud plugin
This commit is contained in:
parent
d477a9222e
commit
d4dea53ae9
2
NEWS
2
NEWS
|
@ -2,6 +2,8 @@ ver 0.19 (not yet released)
|
||||||
* protocol
|
* protocol
|
||||||
- new commands "addtagid", "cleartagid"
|
- new commands "addtagid", "cleartagid"
|
||||||
- "lsinfo" and "readcomments" allowed for remote files
|
- "lsinfo" and "readcomments" allowed for remote files
|
||||||
|
* playlist
|
||||||
|
- soundcloud: use https instead of http
|
||||||
* archive
|
* archive
|
||||||
- read tags from songs in an archive
|
- read tags from songs in an archive
|
||||||
* input
|
* input
|
||||||
|
|
|
@ -67,16 +67,16 @@ soundcloud_resolve(const char* uri)
|
||||||
{
|
{
|
||||||
char *u, *ru;
|
char *u, *ru;
|
||||||
|
|
||||||
if (StringStartsWith(uri, "http://")) {
|
if (StringStartsWith(uri, "https://")) {
|
||||||
u = g_strdup(uri);
|
u = g_strdup(uri);
|
||||||
} else if (StringStartsWith(uri, "soundcloud.com")) {
|
} else if (StringStartsWith(uri, "soundcloud.com")) {
|
||||||
u = g_strconcat("http://", uri, nullptr);
|
u = g_strconcat("https://", uri, nullptr);
|
||||||
} else {
|
} else {
|
||||||
/* assume it's just a path on soundcloud.com */
|
/* assume it's just a path on soundcloud.com */
|
||||||
u = g_strconcat("http://soundcloud.com/", uri, nullptr);
|
u = g_strconcat("https://soundcloud.com/", uri, nullptr);
|
||||||
}
|
}
|
||||||
|
|
||||||
ru = g_strconcat("http://api.soundcloud.com/resolve.json?url=",
|
ru = g_strconcat("https://api.soundcloud.com/resolve.json?url=",
|
||||||
u, "&client_id=",
|
u, "&client_id=",
|
||||||
soundcloud_config.apikey.c_str(), nullptr);
|
soundcloud_config.apikey.c_str(), nullptr);
|
||||||
g_free(u);
|
g_free(u);
|
||||||
|
@ -356,11 +356,11 @@ soundcloud_open_uri(const char *uri, Mutex &mutex, Cond &cond)
|
||||||
|
|
||||||
char *u = nullptr;
|
char *u = nullptr;
|
||||||
if (strcmp(arg, "track") == 0) {
|
if (strcmp(arg, "track") == 0) {
|
||||||
u = g_strconcat("http://api.soundcloud.com/tracks/",
|
u = g_strconcat("https://api.soundcloud.com/tracks/",
|
||||||
rest, ".json?client_id=",
|
rest, ".json?client_id=",
|
||||||
soundcloud_config.apikey.c_str(), nullptr);
|
soundcloud_config.apikey.c_str(), nullptr);
|
||||||
} else if (strcmp(arg, "playlist") == 0) {
|
} else if (strcmp(arg, "playlist") == 0) {
|
||||||
u = g_strconcat("http://api.soundcloud.com/playlists/",
|
u = g_strconcat("https://api.soundcloud.com/playlists/",
|
||||||
rest, ".json?client_id=",
|
rest, ".json?client_id=",
|
||||||
soundcloud_config.apikey.c_str(), nullptr);
|
soundcloud_config.apikey.c_str(), nullptr);
|
||||||
} else if (strcmp(arg, "url") == 0) {
|
} else if (strcmp(arg, "url") == 0) {
|
||||||
|
|
Loading…
Reference in New Issue