aboutsummaryrefslogtreecommitdiffstats
path: root/youtube/accounts.py
diff options
context:
space:
mode:
authorJames Taylor <user234683@users.noreply.github.com>2018-12-26 02:21:20 -0800
committerJames Taylor <user234683@users.noreply.github.com>2018-12-26 02:21:20 -0800
commitb321b5fc6484c38d861530e6b89405b062e32459 (patch)
tree17857ea71377604b887e1242ff596a6817c165d8 /youtube/accounts.py
parentb4aa7cecbc2433a9a734c1896bf24ed57b141884 (diff)
downloadyt-local-b321b5fc6484c38d861530e6b89405b062e32459.tar.lz
yt-local-b321b5fc6484c38d861530e6b89405b062e32459.tar.xz
yt-local-b321b5fc6484c38d861530e6b89405b062e32459.zip
Server-side http logic for adding account
Diffstat (limited to 'youtube/accounts.py')
-rw-r--r--youtube/accounts.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/youtube/accounts.py b/youtube/accounts.py
index a7461c0..9696899 100644
--- a/youtube/accounts.py
+++ b/youtube/accounts.py
@@ -23,11 +23,12 @@ def save_accounts():
def add_account(username, password, save):
cookie_jar = http.cookiejar.LWPCookieJar()
- _login(username, password, cookie_jar)
+ condition = _login(username, password, cookie_jar)
accounts[username] = {
"save":save,
"cookies":cookie_jar.as_lwp_str(ignore_discard=False, ignore_expires=False),
}
+ return condition
def cookie_jar_from_lwp_str(lwp_str):
cookie_jar = http.cookiejar.LWPCookieJar()