Setup ESLint and Prettier and apply changes to sources #891

Merged
IGassmann merged 22 commits from issue/763 into master 2017-12-27 21:22:51 +01:00
Showing only changes of commit f3c92acacf - Show all commits

View file

@ -1,10 +1,10 @@
import * as ACTIONS from 'constants/action_types';
import * as SETTINGS from 'constants/settings';
import Lbry from 'lbry';
import Fs from 'fs';
import Http from 'http';
import Lbry from 'lbry';
export function doFetchDaemonSettings() {
return function(dispatch) {
Lbry.settings_get().then(settings => {
@ -20,14 +20,14 @@ export function doFetchDaemonSettings() {
export function doSetDaemonSetting(key, value) {
return function(dispatch) {
const settings = {};
settings[key] = value;
Lbry.settings_set(settings).then(settings);
Lbry.settings_get().then(remoteSettings => {
const newSettings = {};
newSettings[key] = value;
Lbry.settings_set(newSettings).then(newSettings);
Lbry.settings_get().then(settings => {
dispatch({
type: ACTIONS.DAEMON_SETTINGS_RECEIVED,
data: {
remoteSettings,
settings,
},
});
});