diff --git a/ui/js/actions/app.js b/ui/js/actions/app.js index 0f8a3bcf3..4a3722caf 100644 --- a/ui/js/actions/app.js +++ b/ui/js/actions/app.js @@ -9,7 +9,7 @@ import { } from "selectors/app"; import { doFetchDaemonSettings } from "actions/settings"; import { doAuthenticate } from "actions/user"; -import { doFileList } from "actions/file_info"; +import { doFetchFileInfosAndPublishedClaims } from "actions/file_info"; const { remote, ipcRenderer, shell } = require("electron"); const path = require("path"); @@ -177,7 +177,7 @@ export function doDaemonReady() { dispatch(doAuthenticate()); dispatch({ type: types.DAEMON_READY }); dispatch(doFetchDaemonSettings()); - dispatch(doFileList()); + dispatch(doFetchFileInfosAndPublishedClaims()); }; } diff --git a/ui/js/actions/file_info.js b/ui/js/actions/file_info.js index 7f4f103a0..eb317e484 100644 --- a/ui/js/actions/file_info.js +++ b/ui/js/actions/file_info.js @@ -155,9 +155,3 @@ export function doFetchFileInfosAndPublishedClaims() { if (!isFetchingFileInfo) dispatch(doFileList()); }; } - -export function doEditClaim(fileInfo) { - return function(dispatch, getState) { - dispatch(doNavigate("/publish", fileInfo)); - }; -} diff --git a/ui/js/component/fileActions/index.js b/ui/js/component/fileActions/index.js index 179493408..461e7a14a 100644 --- a/ui/js/component/fileActions/index.js +++ b/ui/js/component/fileActions/index.js @@ -10,9 +10,13 @@ import { makeSelectIsAvailableForUri } from "selectors/availability"; import { makeSelectCostInfoForUri } from "selectors/cost_info"; import { doCloseModal, doOpenModal } from "actions/app"; import { doFetchAvailability } from "actions/availability"; -import { doOpenFileInShell, doOpenFileInFolder, doEditClaim, } from "actions/file_info"; -import { makeSelectClaimForUri,makeSelectClaimForUriIsMine } from "selectors/claims"; +import { doOpenFileInShell, doOpenFileInFolder } from "actions/file_info"; +import { + makeSelectClaimForUri, + makeSelectClaimForUriIsMine, +} from "selectors/claims"; import { doPurchaseUri, doLoadVideo, doStartDownload } from "actions/content"; +import { doNavigate } from "actions/navigation"; import FileActions from "./view"; const makeSelect = () => { @@ -49,7 +53,7 @@ const perform = dispatch => ({ startDownload: uri => dispatch(doPurchaseUri(uri, "affirmPurchase")), loadVideo: uri => dispatch(doLoadVideo(uri)), restartDownload: (uri, outpoint) => dispatch(doStartDownload(uri, outpoint)), - editClaim: fileInfo => dispatch(doEditClaim(fileInfo)), + editClaim: fileInfo => dispatch(doNavigate("/publish", fileInfo)), }); export default connect(makeSelect, perform)(FileActions); diff --git a/ui/js/component/fileActions/view.jsx b/ui/js/component/fileActions/view.jsx index 2012ec409..f7f8a3842 100644 --- a/ui/js/component/fileActions/view.jsx +++ b/ui/js/component/fileActions/view.jsx @@ -191,13 +191,13 @@ class FileActions extends React.PureComponent { label={openInFolderMessage} /> {claimIsMine && + editClaim({ name, channel })} + label={__("Edit claim")} + />} editClaim({ name, channel })} - label={__("Edit claim")} - />} - openModal(modals.CONFIRM_FILE_REMOVE)} label={__("Remove...")} /> diff --git a/ui/js/component/form.js b/ui/js/component/form.js index d47d7445a..4b353eb94 100644 --- a/ui/js/component/form.js +++ b/ui/js/component/form.js @@ -74,11 +74,6 @@ export class FormRow extends React.PureComponent { } getOptions() { - if (!this._field || !this._field.getOptions) { - console.log(this); - console.log(this._field); - console.log(this._field.getOptions); - } return this._field.getOptions(); } diff --git a/ui/js/modal/modalInsufficientBalance/index.js b/ui/js/modal/modalInsufficientBalance/index.js index c56232caf..5e94a9f9e 100644 --- a/ui/js/modal/modalInsufficientBalance/index.js +++ b/ui/js/modal/modalInsufficientBalance/index.js @@ -1,6 +1,7 @@ import React from "react"; import { connect } from "react-redux"; -import { doCloseModal, doNavigate } from "actions/app"; +import { doCloseModal } from "actions/app"; +import { doNavigate } from "actions/navigation"; import ModalInsufficientBalance from "./view"; const select = state => ({}); diff --git a/ui/js/page/settings/view.jsx b/ui/js/page/settings/view.jsx index 8835b0236..c09c1be13 100644 --- a/ui/js/page/settings/view.jsx +++ b/ui/js/page/settings/view.jsx @@ -259,7 +259,6 @@ class SettingsPage extends React.PureComponent {

{__("Theme")}

- {console.log(theme)}