Index: classes/core/Request.inc.php =================================================================== RCS file: /cvs/ojs2/classes/core/Request.inc.php,v --- classes/core/Request.inc.php 2 Dec 2009 06:38:29 -0000 1.71 +++ classes/core/Request.inc.php 11 Dec 2009 22:21:27 -0000 @@ -43,10 +43,7 @@ $_this =& PKPRequest::_checkThis(); if (!isset($journal)) { - $journalArray = $_this->_delegateToRouter('getRequestedContextPath', 1); - $journal = $journalArray[0]; - - // call legacy hook + $journal = $_this->_delegateToRouter('getRequestedContextPath', 1); HookRegistry::call('Request::getRequestedJournalPath', array(&$journal)); } @@ -68,7 +65,14 @@ */ function getRequestedContextPath($contextLevel = null) { $_this =& PKPRequest::_checkThis(); - return $_this->_delegateToRouter('getRequestedContextPath', $contextLevel); + + // Emulate the old behavior of getRequestedContextPath for + // backwards compatibility. + if (is_null($contextLevel)) { + return $_this->_delegateToRouter('getRequestedContextPaths'); + } else { + return array($_this->_delegateToRouter('getRequestedContextPath', $contextLevel)); + } } /**