File tree Expand file tree Collapse file tree 1 file changed +15
-11
lines changed Expand file tree Collapse file tree 1 file changed +15
-11
lines changed Original file line number Diff line number Diff line change @@ -31,18 +31,22 @@ function PushAudiencesStore(state, action) {
31
31
return Parse . Promise . as ( state ) ;
32
32
}
33
33
}
34
- let promise = action . app . apiRequest (
35
- 'GET' ,
36
- action . limit ? `push_audiences?audience_limit=${ action . limit } ` : 'push_audiences' ,
37
- { } ,
38
- { useMasterKey : true }
39
- ) ;
34
+ if ( action . app . serverInfo . parseServerVersion > '2.2.24' ) {
35
+ let promise = action . app . apiRequest (
36
+ 'GET' ,
37
+ action . limit ? `push_audiences?audience_limit=${ action . limit } ` : 'push_audiences' ,
38
+ { } ,
39
+ { useMasterKey : true }
40
+ ) ;
40
41
41
- //xhrMap[action.xhrKey] = xhr;
42
- //
43
- return promise . then ( ( { results, showMore } ) => {
44
- return Map ( { lastFetch : new Date ( ) , audiences : List ( results ) , showMore : showMore } ) ;
45
- } ) ;
42
+ //xhrMap[action.xhrKey] = xhr;
43
+ //
44
+ return promise . then ( ( { results, showMore } ) => {
45
+ return Map ( { lastFetch : new Date ( ) , audiences : List ( results ) , showMore : showMore } ) ;
46
+ } ) ;
47
+ } else {
48
+ return Parse . Promise . as ( state ) ;
49
+ }
46
50
case ActionTypes . CREATE :
47
51
return action . app . apiRequest (
48
52
'POST' ,
You can’t perform that action at this time.
0 commit comments