File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -580,7 +580,7 @@ private void StartListener()
580580
581581 if ( isAuthOk )
582582 {
583- route . Callback . Invoke ( null , new object [ ] { new WebServerEventArgs ( context ) } ) ;
583+ InvokeRoute ( route , context ) ;
584584 }
585585 else
586586 {
@@ -638,6 +638,16 @@ private void StartListener()
638638 }
639639 }
640640
641+ /// <summary>
642+ /// Method which invokes route. Can be overriden to inject custom logic.
643+ /// </summary>
644+ /// <param name="route">Current rounte to invoke. Resolved based on parameters.</param>
645+ /// <param name="context">Context of current request.</param>
646+ protected virtual void InvokeRoute ( CallbackRoutes route , HttpListenerContext context )
647+ {
648+ route . Callback . Invoke ( null , new object [ ] { new WebServerEventArgs ( context ) } ) ;
649+ }
650+
641651 private string GetApiKeyFromHeaders ( WebHeaderCollection headers )
642652 {
643653 var sec = headers . GetValues ( "ApiKey" ) ;
You can’t perform that action at this time.
0 commit comments