From: helge Date: Wed, 9 Feb 2005 11:16:00 +0000 (+0000) Subject: added a small warning X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f62636dddf5fb4f3257f4ae30716142295b7e517;p=sope added a small warning git-svn-id: http://svn.opengroupware.org/SOPE/trunk@543 e4a50df8-12e2-0310-a44c-efbce7f8a7e3 --- diff --git a/sope-appserver/NGObjWeb/ChangeLog b/sope-appserver/NGObjWeb/ChangeLog index a6a2d07e..ee0e6b72 100644 --- a/sope-appserver/NGObjWeb/ChangeLog +++ b/sope-appserver/NGObjWeb/ChangeLog @@ -1,3 +1,8 @@ +2005-02-04 Helge Hess + + * WOApplication.m: added a warning if the default component request + handler key is not set (v4.5.113) + 2005-02-06 Helge Hess * DynamicElements/WOBrowser.m: fixed a warning if neither selection diff --git a/sope-appserver/NGObjWeb/Version b/sope-appserver/NGObjWeb/Version index 28da496b..fe816bee 100644 --- a/sope-appserver/NGObjWeb/Version +++ b/sope-appserver/NGObjWeb/Version @@ -1,6 +1,6 @@ # version file -SUBMINOR_VERSION:=112 +SUBMINOR_VERSION:=113 # v4.5.91 requires libNGExtensions v4.5.134 # v4.5.84 requires libNGExtensions v4.5.127 diff --git a/sope-appserver/NGObjWeb/WOApplication.m b/sope-appserver/NGObjWeb/WOApplication.m index ea8f4af5..86206f3a 100644 --- a/sope-appserver/NGObjWeb/WOApplication.m +++ b/sope-appserver/NGObjWeb/WOApplication.m @@ -57,6 +57,12 @@ static NSString *rapidTurnAroundPath = nil; @implementation WOApplication +#if 1 +static NSString *defaultCompRqHandlerClassName = @"OWViewRequestHandler"; +#else +static NSString *defaultCompRqHandlerClassName = @"WOComponentRequestHandler"; +#endif + + (int)version { return [super version] + 5 /* v6 */; } @@ -265,12 +271,13 @@ static NSString *rapidTurnAroundPath = nil; self->requestHandlerRegistry = NSCreateMapTable(NSObjectMapKeyCallBacks, NSObjectMapValueCallBacks, 8); - rk = [WOApplication componentRequestHandlerKey]; -#if 1 - rh = [[NSClassFromString(@"OWViewRequestHandler") alloc] init]; -#else - rh = [[NSClassFromString(@"WOComponentRequestHandler") alloc] init]; -#endif + if ((rk = [WOApplication componentRequestHandlerKey]) == nil) { + [self logWithFormat: + @"WARNING: no component request handler key is specified, " + @"this probably means that share/ngobjweb/Defaults.plist " + @"could not get loaded (permissions?)"]; + } + rh = [[NSClassFromString(defaultCompRqHandlerClassName) alloc] init]; if ([rk length] > 0 && (rh != nil)) [self registerRequestHandler:rh forKey:rk]; [rh release]; rh = nil;