From ba95a77ed2f26d0e006429f66965b09d30d93419 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=83=9D=E3=83=BC=E3=83=AB=20=E3=82=A6=E3=82=A7=E3=83=83?= =?UTF-8?q?=E3=83=96?= Date: Tue, 14 Aug 2018 17:43:32 -0500 Subject: [PATCH] Slight fixes --- helpers/fetch-metadata.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/helpers/fetch-metadata.js b/helpers/fetch-metadata.js index cd9402a..2bece14 100644 --- a/helpers/fetch-metadata.js +++ b/helpers/fetch-metadata.js @@ -115,9 +115,7 @@ module.exports = exports = (data, socket) => { body: body, json: true, method: apiRequestMethod, - url: `${process.env.NODE_ENV === "development" ? - `http://localhost:5200/${resolveMethod}` : - `http://daemon.lbry.tech/${resolveMethod}`}` + url: `${process.env.NODE_ENV === "development" ? `http://localhost:5200/${resolveMethod}` : `https://daemon.lbry.tech/${resolveMethod}`}` }, (error, response, body) => { if (error) { if (process.env.NODE_ENV !== "development") { @@ -143,7 +141,10 @@ module.exports = exports = (data, socket) => { return resolve(body.error); } - if (body.result.txid) explorerNotice = ` + if ( + body.result && + body.result.txid + ) explorerNotice = `

If you want proof of the tip you just gave, check it out on our blockchain explorer!

`;