mirror of
https://git.lecygnenoir.info/LecygneNoir/prismedia.git
synced 2025-10-03 09:29:16 +02:00
Use docopt default for description instead of "or" when constructing the body (which is duplicate)
This commit is contained in:
parent
4be4a1727e
commit
0295402194
1 changed files with 1 additions and 2 deletions
|
@ -88,7 +88,7 @@ def initialize_upload(youtube, options):
|
||||||
body = {
|
body = {
|
||||||
"snippet": {
|
"snippet": {
|
||||||
"title": options.get('--name') or splitext(basename(path))[0],
|
"title": options.get('--name') or splitext(basename(path))[0],
|
||||||
"description": options.get('--description') or "default description",
|
"description": options.get('--description'),
|
||||||
"tags": tags,
|
"tags": tags,
|
||||||
#if no category, set default to 1 (Films)
|
#if no category, set default to 1 (Films)
|
||||||
"categoryId": str(category or 1),
|
"categoryId": str(category or 1),
|
||||||
|
@ -105,7 +105,6 @@ def initialize_upload(youtube, options):
|
||||||
body=body,
|
body=body,
|
||||||
media_body=MediaFileUpload(path, chunksize=-1, resumable=True)
|
media_body=MediaFileUpload(path, chunksize=-1, resumable=True)
|
||||||
)
|
)
|
||||||
|
|
||||||
resumable_upload(insert_request)
|
resumable_upload(insert_request)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue