File tree 1 file changed +14
-8
lines changed
1 file changed +14
-8
lines changed Original file line number Diff line number Diff line change @@ -156,23 +156,29 @@ class Instance : public Http::StreamDecoderFilter,
156
156
157
157
// mixer control switch (off by default)
158
158
bool mixer_disabled () {
159
- auto route = decoder_callbacks_->route ()-> routeEntry () ;
159
+ auto route = decoder_callbacks_->route ();
160
160
if (route != nullptr ) {
161
- auto key = route->opaqueConfig ().find (kJsonNameMixerSwitch );
162
- if (key != route->opaqueConfig ().end () && key->second == " on" ) {
163
- return false ;
161
+ auto entry = route->routeEntry ();
162
+ if (entry != nullptr ) {
163
+ auto key = entry->opaqueConfig ().find (kJsonNameMixerSwitch );
164
+ if (key != entry->opaqueConfig ().end () && key->second == " on" ) {
165
+ return false ;
166
+ }
164
167
}
165
168
}
166
169
return true ;
167
170
}
168
171
169
172
// attribute forward switch (on by default)
170
173
bool forward_disabled () {
171
- auto route = decoder_callbacks_->route ()-> routeEntry () ;
174
+ auto route = decoder_callbacks_->route ();
172
175
if (route != nullptr ) {
173
- auto key = route->opaqueConfig ().find (kJsonNameForwardSwitch );
174
- if (key != route->opaqueConfig ().end () && key->second == " off" ) {
175
- return true ;
176
+ auto entry = route->routeEntry ();
177
+ if (entry != nullptr ) {
178
+ auto key = entry->opaqueConfig ().find (kJsonNameForwardSwitch );
179
+ if (key != entry->opaqueConfig ().end () && key->second == " off" ) {
180
+ return true ;
181
+ }
176
182
}
177
183
}
178
184
return false ;
You can’t perform that action at this time.
0 commit comments