From c29123e815bf9b4b8d0c06f49f6aa4d1f583f5c8 Mon Sep 17 00:00:00 2001 From: Sean Yesmunt Date: Fri, 10 Jul 2020 12:36:30 -0400 Subject: [PATCH] pass authToken to youtube.HasAuth --- dist/bundle.es.js | 7 ++++--- dist/flow-typed/LbryFirst.js | 2 +- flow-typed/LbryFirst.js | 2 +- src/lbry-first.js | 7 ++++--- 4 files changed, 10 insertions(+), 8 deletions(-) diff --git a/dist/bundle.es.js b/dist/bundle.es.js index 0b56a63..9a3f93b 100644 --- a/dist/bundle.es.js +++ b/dist/bundle.es.js @@ -1275,9 +1275,10 @@ const LbryFirst = { return lbryFirstCallWithResult('youtube.Upload', uploadParams); }, - hasYTAuth: () => { - const emptyParams = {}; - return lbryFirstCallWithResult('youtube.HasAuth', emptyParams); + hasYTAuth: token => { + const hasYTAuthParams = {}; + hasYTAuthParams.AuthToken = token; + return lbryFirstCallWithResult('youtube.HasAuth', hasYTAuthParams); }, ytSignup: () => { diff --git a/dist/flow-typed/LbryFirst.js b/dist/flow-typed/LbryFirst.js index 850fa88..b068f5f 100644 --- a/dist/flow-typed/LbryFirst.js +++ b/dist/flow-typed/LbryFirst.js @@ -94,6 +94,6 @@ declare type LbryFirstTypes = { status: () => Promise, version: () => Promise, upload: any => Promise, - hasYTAuth: () => Promise, + hasYTAuth: string => Promise, ytSignup: () => Promise, }; diff --git a/flow-typed/LbryFirst.js b/flow-typed/LbryFirst.js index 850fa88..b068f5f 100644 --- a/flow-typed/LbryFirst.js +++ b/flow-typed/LbryFirst.js @@ -94,6 +94,6 @@ declare type LbryFirstTypes = { status: () => Promise, version: () => Promise, upload: any => Promise, - hasYTAuth: () => Promise, + hasYTAuth: string => Promise, ytSignup: () => Promise, }; diff --git a/src/lbry-first.js b/src/lbry-first.js index 8b2deb7..4dcb39e 100644 --- a/src/lbry-first.js +++ b/src/lbry-first.js @@ -64,9 +64,10 @@ const LbryFirst: LbryFirstTypes = { return lbryFirstCallWithResult('youtube.Upload', uploadParams); }, - hasYTAuth: () => { - const emptyParams = {}; - return lbryFirstCallWithResult('youtube.HasAuth', emptyParams); + hasYTAuth: (token: string) => { + const hasYTAuthParams = {}; + hasYTAuthParams.AuthToken = token; + return lbryFirstCallWithResult('youtube.HasAuth', hasYTAuthParams); }, ytSignup: () => {