Seaside
Seaside copied to clipboard
Add config option to WADispatcher to redirect instead of answering
WADispatcher>>handleDefault:
automatically delegates to the handler for default name (if defined), but this causes issues with cookie tracking strategies, because the path of the cookie contains the path of the default name (e.g. /app
) instead of the root path (/
) causing unnecessary session creation because the session cookie is not found.
Proposed change
WADispatcher>>handleDefault: aRequestContext
self defaultName isNil
ifTrue: [ aRequestContext responseGenerator forbidden; respond ]
ifFalse: [
self redirectToDefaultName
ifTrue: [aRequestContext redirectTo: self defaultName ]
ifFalse: [self handleFiltered: aRequestContext named: self defaultName ]
]