diff --git a/.gitignore b/.gitignore index c34fbc107..d5e060c7b 100644 --- a/.gitignore +++ b/.gitignore @@ -54,6 +54,7 @@ Tests/node_modules Tests/lib/config.js Tests/results.xml Tests/results +Tests/Unit/SoObjects # SAML2 autogenerated files SoObjects/SOGo/SOGoSAML2Exceptions.* diff --git a/SoObjects/SOGo/SOGoPasswordPolicy.m b/SoObjects/SOGo/SOGoPasswordPolicy.m index 5db36c4a5..b32d66d0e 100644 --- a/SoObjects/SOGo/SOGoPasswordPolicy.m +++ b/SoObjects/SOGo/SOGoPasswordPolicy.m @@ -75,7 +75,7 @@ static const NSString *SPECIAL_SYMBOL_ALLOWED = @"%$&*(){}!?\\@#.,:;+=\\[\\]\\|< NSNumber *value = [policy objectForKey:@"value"]; NSInteger index = [[self policies] indexOfObject: label]; - if (0 < value) { + if (0 < [value intValue]) { NSMutableDictionary *newPolicy = [NSMutableDictionary dictionaryWithDictionary: policy]; [newPolicy setObject:[[self regexPoliciesWithCount: value] objectAtIndex: index] forKey:@"regex"]; [passwordPolicy addObject: newPolicy];