added hash_base system (base refs gets stored in the _SESSION)
[phpgitweb.git] / htdocs / pages / commit.class.php
index 389efaabf38acbbc7837f70a8975840bee8a37c8..57f20e5d8b18def5b68871a9bd58e9595cc67956 100644 (file)
@@ -180,7 +180,6 @@ class difftree {
 
 class page_commit {
     private $page, $phpgitweb;
-       private $commitid;
        
     public function main($phpgitweb, $project) {
                $this->phpgitweb = $phpgitweb;
@@ -189,19 +188,14 @@ class page_commit {
                $project['refs'] = $phpgitweb->get_project_loader()->getProjectRefs($project);
                $phpgitweb->append_header_nav("commit", null, true);
                $phpgitweb->append_title("commit");
+               CommitLoader::parse();
                
                $commit_loader = new CommitLoader($project);
-               
-               if(array_key_exists('h', $_GET))
-                       $commitid = $_GET['h'];
-               else
-                       $commitid = "HEAD";
-               
-               $commit = $commit_loader->load($commitid);
+               $commit = $commit_loader->load();
                if(!$commit)
                        return new ContentProvider('main', 'err404_object');
                
-               ContentProvider::overall_set('project_head', $commit['id']);
+               ContentProvider::overall_set('commit_id', $commit['id']);
                
                
                $this->page = new ContentProvider('commit', 'main');