Monotone-Parent: bcb224398f8aef1d62aad42e31635b91c0c993f7

Monotone-Revision: 01c5e5314c26ef13463ba2e2dec3d854ef793f1d

Monotone-Author: wsourdeau@inverse.ca
Monotone-Date: 2010-03-09T20:33:00
Monotone-Branch: ca.inverse.sogo
maint-2.0.2
Wolfgang Sourdeau 2010-03-09 20:33:00 +00:00
parent 2b03a58b9d
commit 3b056b3226
3 changed files with 13 additions and 9 deletions

View File

@ -1,5 +1,9 @@
2010-03-09 Wolfgang Sourdeau <wsourdeau@inverse.ca>
* UI/Common/WODirectAction+SOGo.m
(-responseWithStatus:andJSONRepresentation:): we now add the
"application/json" content type to the response object.
* UI/SOGoUI/UIxComponent.m
(-responseWithStatus:andJSONRepresentation:): we now add the
"application/json" content type to the response object.

View File

@ -60,8 +60,13 @@
- (WOResponse *) responseWithStatus: (unsigned int) status
andJSONRepresentation: (NSObject *) contentObject;
{
return [self responseWithStatus: status
andString: [contentObject jsonRepresentation]];
WOResponse *response;
response = [self responseWithStatus: status
andString: [contentObject jsonRepresentation]];
[response setHeader: @"application/json" forKey: @"content-type"];
return response;
}
- (WOResponse *) responseWith204

View File

@ -113,18 +113,13 @@
/* actions */
- (WOResponse *) _responseWithLDAPPolicyError: (int) error
{
WOResponse *response;
NSDictionary *jsonError;
jsonError
= [NSDictionary dictionaryWithObject: [NSNumber numberWithInt: error]
forKey: @"LDAPPasswordPolicyError"];
response = [self responseWithStatus: 403
andJSONRepresentation: jsonError];
[response setHeader: @"application/json"
forKey: @"content-type"];
return response;
return [self responseWithStatus: 403
andJSONRepresentation: jsonError];
}
- (id <WOActionResults>) connectAction