From 118ca9f11fa5ba7eb54641394bf6edd75f9227c0 Mon Sep 17 00:00:00 2001 From: Thomas Keller Date: Fri, 10 Jun 2011 23:40:58 +0200 Subject: [PATCH] Now that IDF_Scm::getChanges() is implemented for all SCMs, there is no need for the try-catch anymore. --- src/IDF/Views/Source.php | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/IDF/Views/Source.php b/src/IDF/Views/Source.php index a50c9c2..758830c 100644 --- a/src/IDF/Views/Source.php +++ b/src/IDF/Views/Source.php @@ -58,7 +58,7 @@ class IDF_Views_Source $title = sprintf(__('%s Invalid Revision'), (string) $request->project); $scm = IDF_Scm::get($request->project); $branches = $scm->getBranches(); - + $commit = $match[2]; $params = array( 'page_title' => $title, @@ -307,12 +307,7 @@ class IDF_Views_Source $cobject->diff = null; $diff->parse(); $scmConf = $request->conf->getVal('scm', 'git'); - try { - $changes = $scm->getChanges($commit); - } catch (Exception $e) { - // getChanges is not yes supported by this backend. - $changes = array(); - } + $changes = $scm->getChanges($commit); $branches = $scm->getBranches(); $in_branches = $scm->inBranches($cobject->commit, ''); $tags = $scm->getTags(); @@ -477,7 +472,7 @@ class IDF_Views_Source } // compare two nodes of different types, directories ("tree") - // should come before files ("blob") + // should come before files ("blob") if ($a->type > $b->type) { return -1; }