File tree Expand file tree Collapse file tree 2 files changed +7
-14
lines changed
BetterModules.Core.Web/Environment/Host Expand file tree Collapse file tree 2 files changed +7
-14
lines changed Original file line number Diff line number Diff line change 8
8
using System . Web . Mvc ;
9
9
using BetterModules . Core . Exceptions ;
10
10
using BetterModules . Core . Web . Exceptions . Host ;
11
+ using BetterModules . Events ;
11
12
using Common . Logging ;
12
13
using RazorGenerator . Mvc ;
13
14
@@ -113,6 +114,7 @@ public virtual void OnEndRequest(HttpApplication application)
113
114
114
115
public virtual void OnAuthenticateRequest ( HttpApplication application )
115
116
{
117
+ WebCoreEvents . Instance . OnHostAuthenticateRequest ( application ) ;
116
118
}
117
119
118
120
public virtual void OnApplicationStart ( HttpApplication application , bool validateViewEngines = true )
@@ -140,6 +142,11 @@ public virtual void OnApplicationEnd(HttpApplication application)
140
142
141
143
public virtual void OnApplicationError ( HttpApplication application )
142
144
{
145
+ var error = application . Server . GetLastError ( ) ;
146
+ Logger . Fatal ( "Unhandled exception occurred in web host application." , error ) ;
147
+
148
+ // Notify.
149
+ WebCoreEvents . Instance . OnHostError ( application ) ;
143
150
}
144
151
145
152
public virtual void OnBeginRequest ( HttpApplication application )
Original file line number Diff line number Diff line change @@ -41,19 +41,5 @@ public override void Dispose()
41
41
}
42
42
}
43
43
}
44
-
45
- public override void OnApplicationError ( HttpApplication application )
46
- {
47
- var error = application . Server . GetLastError ( ) ;
48
- Logger . Fatal ( "Unhandled exception occurred in web host application." , error ) ;
49
-
50
- // Notify.
51
- WebCoreEvents . Instance . OnHostError ( application ) ;
52
- }
53
-
54
- public override void OnAuthenticateRequest ( HttpApplication application )
55
- {
56
- WebCoreEvents . Instance . OnHostAuthenticateRequest ( application ) ;
57
- }
58
44
}
59
45
}
You can’t perform that action at this time.
0 commit comments