Differential D14970 Diff 36173 src/applications/diffusion/controller/DiffusionRepositoryController.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/diffusion/controller/DiffusionRepositoryController.php
| Show First 20 Lines • Show All 155 Lines • ▼ Show 20 Lines | try { | ||||
| $browse_results = null; | $browse_results = null; | ||||
| $browse_paths = null; | $browse_paths = null; | ||||
| $browse_exception = $ex; | $browse_exception = $ex; | ||||
| } | } | ||||
| $phids = array_keys($phids); | $phids = array_keys($phids); | ||||
| $handles = $this->loadViewerHandles($phids); | $handles = $this->loadViewerHandles($phids); | ||||
| $readme = null; | |||||
| if ($browse_results) { | if ($browse_results) { | ||||
| $readme_path = $browse_results->getReadmePath(); | $readme = $this->renderDirectoryReadme($browse_results); | ||||
| if ($readme_path) { | } else { | ||||
| $readme_content = $this->callConduitWithDiffusionRequest( | $readme = null; | ||||
| 'diffusion.filecontentquery', | |||||
| array( | |||||
| 'path' => $readme_path, | |||||
| 'commit' => $drequest->getStableCommit(), | |||||
| )); | |||||
| if ($readme_content) { | |||||
| $readme = id(new DiffusionReadmeView()) | |||||
| ->setUser($this->getViewer()) | |||||
| ->setPath($readme_path) | |||||
| ->setContent($readme_content['corpus']); | |||||
| } | |||||
| } | |||||
| } | } | ||||
| $content[] = $this->buildBrowseTable( | $content[] = $this->buildBrowseTable( | ||||
| $browse_results, | $browse_results, | ||||
| $browse_paths, | $browse_paths, | ||||
| $browse_exception, | $browse_exception, | ||||
| $handles, | $handles, | ||||
| $browse_pager); | $browse_pager); | ||||
| ▲ Show 20 Lines • Show All 583 Lines • Show Last 20 Lines | |||||