mirror of
https://github.com/LBRYFoundation/lbry.com.git
synced 2025-08-23 17:47:26 +00:00
adjusting deprecated APIs
This commit is contained in:
parent
917f1689bb
commit
66324c3f0e
2 changed files with 6 additions and 6 deletions
8
lib/thirdparty/LBRY.class.php
vendored
8
lib/thirdparty/LBRY.class.php
vendored
|
@ -31,23 +31,23 @@ class LBRY
|
|||
|
||||
public static function editEmailSettings($token, $email, $isPrimary =null, $isEnabled = null)
|
||||
{
|
||||
return Curl::post(static::getApiUrl('/user/email/edit'), ['auth_token' => $token], ['email' => $email], ['is_primary' => $isPrimary], ['is_enabled' => $isEnabled]);
|
||||
return Curl::post(static::getApiUrl('/user_email/edit'), ['auth_token' => $token], ['email' => $email], ['is_primary' => $isPrimary], ['is_enabled' => $isEnabled]);
|
||||
}
|
||||
|
||||
public static function emailStatus($token)
|
||||
{
|
||||
list($status, $headers, $body) = Curl::doCurl(Curl::POST, static::getApiUrl('/user/email/status'),['auth_token' => $token], ['json_response' => true]);
|
||||
list($status, $headers, $body) = Curl::doCurl(Curl::POST, static::getApiUrl('/user_email/status'), ['auth_token' => $token], ['json_response' => true]);
|
||||
return array($status,$headers,$body);
|
||||
}
|
||||
|
||||
public static function applyTags($type, $token, $tags)
|
||||
{
|
||||
return Curl::post(static::getApiUrl('/user/tag/edit'), ['auth_token' => $token], [$type => $tags]);
|
||||
return Curl::post(static::getApiUrl('/user_tag/edit'), ['auth_token' => $token], [$type => $tags]);
|
||||
}
|
||||
|
||||
public static function unsubscribe($email)
|
||||
{
|
||||
return Curl::post(static::getApiUrl('/list/unsubscribe'), ['email' => $email], ['json_response' => true]);
|
||||
return Curl::post(static::getApiUrl('/user/unsubscribe'), ['email' => $email], ['json_response' => true]);
|
||||
}
|
||||
|
||||
public static function connectYoutube($channel_name)
|
||||
|
|
|
@ -14,7 +14,7 @@ lbry.emailSettingsForm = function (formSelector, tags, userAuthToken) {
|
|||
|
||||
function submitEmail(e) {
|
||||
var element = e.target,
|
||||
url = 'https://api.lbry.io/user/email/edit?auth_token=' + userAuthToken
|
||||
url = 'https://api.lbry.io/user_email/edit?auth_token=' + userAuthToken
|
||||
+ "&email=" + element.value + "&enabled=" + element.checked.toString();
|
||||
|
||||
emailSection.find('.notice').hide();
|
||||
|
@ -30,7 +30,7 @@ lbry.emailSettingsForm = function (formSelector, tags, userAuthToken) {
|
|||
|
||||
function submitTags() {
|
||||
tagSection.find('.notice').hide();
|
||||
var url = 'https://api.lbry.io/user/tag/edit?auth_token=' + userAuthToken,
|
||||
var url = 'https://api.lbry.io/user_tag/edit?auth_token=' + userAuthToken,
|
||||
addTags = [],
|
||||
removeTags = [];
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue