File tree 2 files changed +6
-6
lines changed
2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change 15
15
//
16
16
// You can specify all the values or you can default the Revision and Build Numbers
17
17
// by using the '*' as shown below:
18
- [ assembly: AssemblyVersion ( "3.2.20 " ) ]
19
- [ assembly: AssemblyFileVersion ( "3.2.20 " ) ]
18
+ [ assembly: AssemblyVersion ( "3.2.21 " ) ]
19
+ [ assembly: AssemblyFileVersion ( "3.2.21 " ) ]
20
20
//[assembly: AssemblyInformationalVersion("2.5-filters")]
Original file line number Diff line number Diff line change @@ -37,8 +37,8 @@ public override void OnActionExecuting(ActionExecutingContext filterContext)
37
37
38
38
var actionParams = new List < KeyValuePair < string , object > > ( filterContext . ActionParameters ) ;
39
39
//add any properties of model classes
40
- foreach ( var ap in filterContext . ActionParameters . Where ( x => x . Value ? . GetType ( ) . IsClass == true ) )
41
- foreach ( var pi in ap . Value . GetType ( ) . GetProperties ( ) . Where ( x => x . CanRead ) )
40
+ foreach ( var ap in filterContext . ActionParameters . Where ( x => x . Value ? . GetType ( ) . IsClass == true && x . Value . GetType ( ) != typeof ( string ) ) )
41
+ foreach ( var pi in ap . Value . GetType ( ) . GetProperties ( ) . Where ( x => x . CanRead && x . GetIndexParameters ( ) . Length == 0 ) )
42
42
actionParams . Add ( new KeyValuePair < string , object > ( pi . Name , pi . GetValue ( ap . Value ) ) ) ;
43
43
44
44
foreach ( var param in actionParams )
@@ -103,9 +103,9 @@ public override void OnActionExecuted(ActionExecutedContext filterContext)
103
103
// now, we could use the context.Parameters... but the raw string values seems more like what we want here...
104
104
foreach ( var param in filterContext . ActionDescriptor . GetParameters ( ) )
105
105
{
106
- if ( param . ParameterType . IsClass )
106
+ if ( param . ParameterType . IsClass && param . ParameterType != typeof ( string ) )
107
107
{
108
- foreach ( var pi in param . ParameterType . GetProperties ( ) )
108
+ foreach ( var pi in param . ParameterType . GetProperties ( ) . Where ( x => x . CanRead && x . GetIndexParameters ( ) . Length == 0 ) )
109
109
AddParameter ( filterContext , data , pi . Name ) ;
110
110
}
111
111
else
You can’t perform that action at this time.
0 commit comments