Skip to content

Commit

Permalink
[webui] fix always empty file list on package overview page
Browse files Browse the repository at this point in the history
  • Loading branch information
adrianschroeter committed Sep 19, 2012
1 parent 269d8cc commit f989835
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions src/webui/app/controllers/package_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,26 @@ def show
@revision = params[:rev]
fill_status_cache unless @buildresult.blank?
set_linking_packages
# for file list in overview page
@expand = 1
@expand = begin Integer(params[:expand]) rescue 1 end if params[:expand]
@expand = 0 if @spider_bot
begin
set_file_details
rescue ActiveXML::Transport::Error => e
message, _, _ = ActiveXML::Transport.extract_error_message e
if @expand == 1
@expand = 0
flash[:error] = "Files could not be expanded: " + message
begin
set_file_details
rescue ActiveXML::Transport::Error => e
message, _, _ = ActiveXML::Transport.extract_error_message e
# seems really bad even without expand
flash[:error] = "Files could not be expanded: " + message
end
end
end
begin
@current_rev = Package.current_rev(@project.name, @package.name)
#TODO generate file list here:
Expand Down

0 comments on commit f989835

Please sign in to comment.