Interactive interface for browsing global, full-resolution satellite imagery
Remove unused migration-module code
Benjamin Kingbd9c36e2927d
diff --git a/web/js/app.js b/web/js/app.jsindex e9698f69d..afe9e7b4f 100644--- a/web/js/app.js+++ b/web/js/app.js@@ -15,11 +15,7 @@ import Modal from './containers/modal';// Otherimport Brand from './brand';-// Crutch between state systems-import { updateLegacyInitComplete } from './modules/migration/actions';-// actions-// import { screenResize } from './modules/browser/actions';import { calculateResponsiveState } from 'redux-responsive';import Tour from './containers/tour';import Timeline from './containers/timeline/timeline';@@ -156,14 +152,12 @@ class App extends React.Component {});self.props.screenResize(window);models.wv.events.trigger('startup');- self.props.updateLegacyInitComplete(); // notify state that legacy initiation has finished};util.wrap(main)();}}function mapStateToProps(state, ownProps) {return {- legacy: state.legacy,state: state,config: state.config,parameters: state.parameters,@@ -172,9 +166,6 @@ function mapStateToProps(state, ownProps) {};}const mapDispatchToProps = dispatch => ({- updateLegacyInitComplete: () => {- dispatch(updateLegacyInitComplete());- },keyPressAction: keyCode => {dispatch({ type: 'KEY_PRESS_ACTION', keyCode });},diff --git a/web/js/modules/combine-reducers.js b/web/js/modules/combine-reducers.jsindex 1acd2a3fe..ec8ce4d3f 100644--- a/web/js/modules/combine-reducers.js+++ b/web/js/modules/combine-reducers.js@@ -1,7 +1,6 @@import { combineReducers } from 'redux';import { createResponsiveStateReducer } from 'redux-responsive';import { modalReducer, modalAboutPage } from './modal/reducers';-import legacyReducer from './migration/reducers';import feedbackReducer from './feedback/reducers';import projectionReducer from './projection/reducer';import { shortLink } from './link/reducers';@@ -80,7 +79,6 @@ const defaultReducer = (state = {}) => state;const reducers = {proj: projectionReducer,modal: modalReducer,- legacy: legacyReducer,date: dateReducer,feedback: feedbackReducer,notifications: notificationsReducer,diff --git a/web/js/modules/migration/actions.js b/web/js/modules/migration/actions.jsdeleted file mode 100644index 2be34440e..000000000--- a/web/js/modules/migration/actions.js+++ /dev/null@@ -1,26 +0,0 @@-import {- CONFIG_HAS_BEEN_LOADED,- INIT_COMPLETE,- UPDATE_IN_LEGACY_STATE-} from './constants';--export function sendConfigToStore(models, config) {- return {- type: CONFIG_HAS_BEEN_LOADED,- models: models,- config: config- };-}--export function updateLegacyModule(key, model) {- return {- type: UPDATE_IN_LEGACY_STATE,- key: key,- model: model- };-}-export function updateLegacyInitComplete() {- return {- type: INIT_COMPLETE- };-}diff --git a/web/js/modules/migration/constants.js b/web/js/modules/migration/constants.jsdeleted file mode 100644index 197ce7628..000000000--- a/web/js/modules/migration/constants.js+++ /dev/null@@ -1,4 +0,0 @@-export const CONFIG_HAS_BEEN_LOADED = 'CONFIG_AND_MODELS_HAVE_BEEN_LOADED';-export const UPDATE_IN_LEGACY_STATE =- 'AN_UPDATE_TO_LEGACY_STATE_MODULE_HAS_OCCURED';-export const INIT_COMPLETE = 'LEGACY_MODELS_INIT_COMPLETE';diff --git a/web/js/modules/migration/reducers.js b/web/js/modules/migration/reducers.jsdeleted file mode 100644index a481838f1..000000000--- a/web/js/modules/migration/reducers.js+++ /dev/null@@ -1,20 +0,0 @@-import update from 'immutability-helper';--const legacyState = {- loaded: false,- map: { ui: { selected: null }, rotation: 0, extent: [] },- initComplete: false-};--export default function legacyReducer(state = legacyState, action) {- switch (action.type) {- case 'MAP/UPDATE_MAP_EXTENT':- return update(state, { map: { extent: { $set: action.extent } } });- case 'MAP/UPDATE_MAP_UI':- return update(state, { map: { ui: { $set: action.ui } } });- case 'MAP/UPDATE_ROTATION':- return update(state, { map: { rotation: { $set: action.rotation } } });- default:- return state;- }-}diff --git a/web/js/modules/migration/util.js b/web/js/modules/migration/util.jsdeleted file mode 100644index e69de29bb..000000000