Parcourir la source

calendar-sync: fix loading calendar entries

Checking if the calendar support in the reducer is not only useless but wrong,
since we don't have access to the entire store (the calendar support is checked
in the base/config feature). If calendar support is not enabled the actions
being reduced won't be dispatched anyway, so no harm is done by removing the
check.
master
Saúl Ibarra Corretgé il y a 6 ans
Parent
révision
ca11cbf6cc
1 fichiers modifiés avec 0 ajouts et 5 suppressions
  1. 0
    5
      react/features/calendar-sync/reducer.js

+ 0
- 5
react/features/calendar-sync/reducer.js Voir le fichier

@@ -13,7 +13,6 @@ import {
13 13
     SET_CALENDAR_PROFILE_EMAIL,
14 14
     SET_LOADING_CALENDAR_EVENTS
15 15
 } from './actionTypes';
16
-import { isCalendarEnabled } from './functions';
17 16
 
18 17
 /**
19 18
  * The default state of the calendar feature.
@@ -50,10 +49,6 @@ PersistenceRegistry.register(STORE_NAME, {
50 49
 });
51 50
 
52 51
 ReducerRegistry.register(STORE_NAME, (state = DEFAULT_STATE, action) => {
53
-    if (!isCalendarEnabled(state)) {
54
-        return state;
55
-    }
56
-
57 52
     switch (action.type) {
58 53
     case CLEAR_CALENDAR_INTEGRATION:
59 54
         return DEFAULT_STATE;

Chargement…
Annuler
Enregistrer