File tree Expand file tree Collapse file tree 5 files changed +25
-5
lines changed Expand file tree Collapse file tree 5 files changed +25
-5
lines changed Original file line number Diff line number Diff line change @@ -1096,7 +1096,11 @@ var AltStore = (function () {
1096
1096
getState : {
1097
1097
value : function getState ( ) {
1098
1098
// Copy over state so it's RO.
1099
- return assign ( { } , this [ STATE_CONTAINER ] ) ;
1099
+ var state = this [ STATE_CONTAINER ] ;
1100
+ return Object . keys ( state ) . reduce ( function ( obj , key ) {
1101
+ obj [ key ] = state [ key ] ;
1102
+ return obj ;
1103
+ } , { } ) ;
1100
1104
}
1101
1105
}
1102
1106
} ) ;
Original file line number Diff line number Diff line change @@ -844,7 +844,11 @@ var AltStore = (function () {
844
844
getState : {
845
845
value : function getState ( ) {
846
846
// Copy over state so it's RO.
847
- return assign ( { } , this [ STATE_CONTAINER ] ) ;
847
+ var state = this [ STATE_CONTAINER ] ;
848
+ return Object . keys ( state ) . reduce ( function ( obj , key ) {
849
+ obj [ key ] = state [ key ] ;
850
+ return obj ;
851
+ } , { } ) ;
848
852
}
849
853
}
850
854
} ) ;
Original file line number Diff line number Diff line change @@ -101,7 +101,11 @@ var AltStore = (function () {
101
101
getState : {
102
102
value : function getState ( ) {
103
103
// Copy over state so it's RO.
104
- return assign ( { } , this [ STATE_CONTAINER ] ) ;
104
+ var state = this [ STATE_CONTAINER ] ;
105
+ return Object . keys ( state ) . reduce ( function ( obj , key ) {
106
+ obj [ key ] = state [ key ] ;
107
+ return obj ;
108
+ } , { } ) ;
105
109
}
106
110
}
107
111
} ) ;
Original file line number Diff line number Diff line change @@ -113,7 +113,11 @@ var AltStore = (function () {
113
113
getState : {
114
114
value : function getState ( ) {
115
115
// Copy over state so it's RO.
116
- return assign ( { } , this [ STATE_CONTAINER ] ) ;
116
+ var state = this [ STATE_CONTAINER ] ;
117
+ return Object . keys ( state ) . reduce ( function ( obj , key ) {
118
+ obj [ key ] = state [ key ] ;
119
+ return obj ;
120
+ } , { } ) ;
117
121
}
118
122
}
119
123
} ) ;
Original file line number Diff line number Diff line change @@ -90,7 +90,11 @@ class AltStore {
90
90
91
91
getState ( ) {
92
92
// Copy over state so it's RO.
93
- return assign ( { } , this [ STATE_CONTAINER ] )
93
+ const state = this [ STATE_CONTAINER ]
94
+ return Object . keys ( state ) . reduce ( ( obj , key ) => {
95
+ obj [ key ] = state [ key ]
96
+ return obj
97
+ } , { } )
94
98
}
95
99
}
96
100
You can’t perform that action at this time.
0 commit comments