Merge pull request #2298 from candidasa/defect51-timeout-message

BUG adding a more descriptive message when the CMS session times out. It...
This commit is contained in:
Mateusz U 2013-08-06 15:13:23 -07:00
commit 00e0bf10ab

View File

@ -188,7 +188,10 @@ class Security extends Controller {
if(Director::is_ajax()) {
$response = ($controller) ? $controller->getResponse() : new SS_HTTPResponse();
$response->setStatusCode(403);
if(!Member::currentUser()) $response->setBody('NOTLOGGEDIN:');
if(!Member::currentUser()) {
$response->setBody(_t('ContentController.NOTLOGGEDIN','Not logged in'));
$response->setStatusDescription(_t('ContentController.NOTLOGGEDIN','Not logged in'));
}
return $response;
} else {
// Prepare the messageSet provided