File tree Expand file tree Collapse file tree 2 files changed +153
-215
lines changed
Expand file tree Collapse file tree 2 files changed +153
-215
lines changed Original file line number Diff line number Diff line change @@ -69,6 +69,9 @@ class ForwardingProxy {
6969 if (specifiesCurrentOrClosedLedger (request))
7070 return true ;
7171
72+ if (isForcedForward (ctx))
73+ return true ;
74+
7275 auto const checkAccountInfoForward = [&]() {
7376 return ctx.method == " account_info" and request.contains (" queue" ) and request.at (" queue" ).is_bool () and
7477 request.at (" queue" ).as_bool ();
@@ -138,6 +141,14 @@ class ForwardingProxy {
138141 {
139142 return handlerProvider_->contains (method) || isProxied (method);
140143 }
144+
145+ bool
146+ isForcedForward (web::Context const & ctx) const
147+ {
148+ static constexpr auto FORCE_FORWARD = " force_forward" ;
149+ return ctx.isAdmin and ctx.params .contains (FORCE_FORWARD) and ctx.params .at (FORCE_FORWARD).is_bool () and
150+ ctx.params .at (FORCE_FORWARD).as_bool ();
151+ }
141152};
142153
143154} // namespace rpc::impl
You can’t perform that action at this time.
0 commit comments