Common components refactor #1
2 changed files with 21 additions and 0 deletions
|
@ -1331,6 +1331,15 @@ Lbry.claim_list_mine = function () {
|
|||
});
|
||||
};
|
||||
|
||||
Lbry.get = function () {
|
||||
var params = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
||||
return new Promise(function (resolve, reject) {
|
||||
apiCall('get', params, function (streamInfo) {
|
||||
resolve(streamInfo);
|
||||
}, reject);
|
||||
});
|
||||
};
|
||||
|
||||
Lbry.resolve = function () {
|
||||
var params = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
||||
return new Promise(function (resolve, reject) {
|
||||
|
|
12
src/lbry.js
12
src/lbry.js
|
@ -294,6 +294,18 @@ Lbry.claim_list_mine = (params = {}) =>
|
|||
reject
|
||||
);
|
||||
});
|
||||
|
||||
Lbry.get = (params = {}) =>
|
||||
new Promise((resolve, reject) => {
|
||||
apiCall(
|
||||
'get',
|
||||
params,
|
||||
streamInfo => {
|
||||
resolve(streamInfo)
|
||||
},
|
||||
reject
|
||||
);
|
||||
});
|
||||
|
||||
Lbry.resolve = (params = {}) =>
|
||||
new Promise((resolve, reject) => {
|
||||
|
|
Loading…
Reference in a new issue