Fixed to have a simpler code.

This commit is contained in:
Loic d'Anterroches 2010-04-15 15:38:03 +02:00
parent 2ad13a96f9
commit 45fa309c07

View File

@ -232,9 +232,7 @@ class IDF_Plugin_SyncMercurial
*/
public function processSyncTimeline($params)
{
$repo_dir = $params['rel_dir'];
$elts = preg_split('#/#', $repo_dir, -1, PREG_SPLIT_NO_EMPTY);
$pname = array_pop($elts);
$pname = basename($params['rel_dir']);
try {
$project = IDF_Project::getOr404($pname);
} catch (Pluf_HTTP_Error404 $e) {