From 50d7b3ab709b6e69d6059856480d51191d11f1da Mon Sep 17 00:00:00 2001 From: hackrush Date: Sun, 30 Jul 2017 00:52:17 +0530 Subject: [PATCH] (quickfix) Now displays quit button in IncompatibleDaemonModal. Also display a Learn More link pointing to the appropriate faq. --- ui/js/actions/app.js | 3 +-- .../modalIncompatibleDaemon/{index.jsx => index.js} | 3 +-- ui/js/component/modalIncompatibleDaemon/view.jsx | 13 +++++++++---- 3 files changed, 11 insertions(+), 8 deletions(-) rename ui/js/component/modalIncompatibleDaemon/{index.jsx => index.js} (70%) diff --git a/ui/js/actions/app.js b/ui/js/actions/app.js index c8586de86..44964b0ba 100644 --- a/ui/js/actions/app.js +++ b/ui/js/actions/app.js @@ -297,9 +297,8 @@ export function doClearCache() { }; } -export function doQuitAndLaunchDaemonHelp() { +export function doQuit() { return function(dispatch, getState) { - shell.openExternal("https://lbry.io/faq/incompatible-protocol-version"); remote.app.quit(); }; } diff --git a/ui/js/component/modalIncompatibleDaemon/index.jsx b/ui/js/component/modalIncompatibleDaemon/index.js similarity index 70% rename from ui/js/component/modalIncompatibleDaemon/index.jsx rename to ui/js/component/modalIncompatibleDaemon/index.js index 27ddecd8d..669e67316 100644 --- a/ui/js/component/modalIncompatibleDaemon/index.jsx +++ b/ui/js/component/modalIncompatibleDaemon/index.js @@ -1,13 +1,12 @@ import React from "react"; import { connect } from "react-redux"; import { doQuit, doSkipWrongDaemonNotice } from "actions/app"; -import { doQuitAndLaunchDaemonHelp } from "actions/app"; import ModalIncompatibleDaemon from "./view"; const select = state => ({}); const perform = dispatch => ({ - quitAndLaunchDaemonHelp: () => dispatch(doQuitAndLaunchDaemonHelp()), + quit: () => dispatch(doQuit()), }); export default connect(select, perform)(ModalIncompatibleDaemon); diff --git a/ui/js/component/modalIncompatibleDaemon/view.jsx b/ui/js/component/modalIncompatibleDaemon/view.jsx index 851a2ec88..bf5c3a84d 100644 --- a/ui/js/component/modalIncompatibleDaemon/view.jsx +++ b/ui/js/component/modalIncompatibleDaemon/view.jsx @@ -1,21 +1,26 @@ import React from "react"; import { Modal } from "component/modal"; +import Link from "component/link"; class ModalIncompatibleDaemon extends React.PureComponent { render() { - const { quitAndLaunchDaemonHelp } = this.props; + const { quit } = this.props; return ( {__( - "This browser is running with an incompatible version of the LBRY protocol and your install must be repaired." + "This browser is running with an incompatible version of the LBRY protocol and your install must be repaired. " )} + ); } -- 2.45.2