File tree 1 file changed +2
-2
lines changed
src/routes/DronesMap/modules
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 1
1
import { handleActions } from 'redux-actions' ;
2
2
import io from 'socket.io-client' ;
3
3
import APIService from 'services/APIService' ;
4
- import config from '../../../../ config/default ' ;
4
+ import config from '../../../config/index ' ;
5
5
6
6
// Drones will be updated and map will be redrawn every 3s
7
7
// Otherwise if drones are updated with high frequency (e.g. 0.5s), the map will be freezing
@@ -32,7 +32,7 @@ export const init = () => async(dispatch) => {
32
32
const { body : { items : drones } } = await APIService . searchDrones ( { limit : DRONE_LIMIT } ) ;
33
33
lastUpdated = new Date ( ) . getTime ( ) ;
34
34
dispatch ( { type : DRONES_LOADED , payload : { drones} } ) ;
35
- socket = io ( config . API_BASE_PATH ) ;
35
+ socket = io ( config . socket . url ) ;
36
36
socket . on ( 'dronepositionupdate' , ( drone ) => {
37
37
pendingUpdates [ drone . id ] = drone ;
38
38
if ( updateTimeoutId ) {
You can’t perform that action at this time.
0 commit comments