From 4c8d649830b980cd5676969e9864999c8ef0d376 Mon Sep 17 00:00:00 2001 From: Jeremy Kauffman Date: Wed, 14 Jun 2017 17:49:23 -0400 Subject: [PATCH] updates required for lbry daemon 0.12 --- build/DAEMON_URL | 2 +- ui/js/actions/content.js | 11 +++++------ ui/js/lbry.js | 2 +- 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/build/DAEMON_URL b/build/DAEMON_URL index 5544239f9..35868e36f 100644 --- a/build/DAEMON_URL +++ b/build/DAEMON_URL @@ -1 +1 @@ -https://github.com/lbryio/lbry/releases/download/v0.11.0/lbrynet-daemon-v0.11.0-OSNAME.zip +https://github.com/lbryio/lbry/releases/download/v0.12.2rc2/lbrynet-daemon-v0.12.2rc2-OSNAME.zip diff --git a/ui/js/actions/content.js b/ui/js/actions/content.js index ca174b261..0daeeadaf 100644 --- a/ui/js/actions/content.js +++ b/ui/js/actions/content.js @@ -246,23 +246,22 @@ export function doPurchaseUri(uri, purchaseModalName) { }; } -export function doFetchClaimsByChannel(uri) { +export function doFetchClaimsByChannel(uri, page = 1) { return function(dispatch, getState) { dispatch({ type: types.FETCH_CHANNEL_CLAIMS_STARTED, data: { uri }, }); - lbry.resolve({ uri }).then(resolutionInfo => { - const { claims_in_channel } = resolutionInfo - ? resolutionInfo - : { claims_in_channel: [] }; + lbry.claim_list_by_channel({ uri, page }).then(result => { + const claimResult = result[uri], + claims = claimResult ? claimResult.claims_in_channel : []; dispatch({ type: types.FETCH_CHANNEL_CLAIMS_COMPLETED, data: { uri, - claims: claims_in_channel, + claims: claims, }, }); }); diff --git a/ui/js/lbry.js b/ui/js/lbry.js index a04ad50f8..55b6b022c 100644 --- a/ui/js/lbry.js +++ b/ui/js/lbry.js @@ -524,7 +524,7 @@ lbry.resolve = function(params = {}) { lbry._claimCache[params.uri] = data; } setSession(claimCacheKey, lbry._claimCache); - resolve(data); + resolve(data && data[params.uri] ? data[params.uri] : {}); }, reject );