Skip to content

Commit

Permalink
Fixed another unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
parthaa committed Jan 6, 2012
1 parent 3042e02 commit 541174b
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/app/models/system_task.rb
Expand Up @@ -152,10 +152,12 @@ def message_for task
end

def refresh(ids)
uuids = TaskStatus.select(:uuid).where(:id => ids).collect{|t| t.uuid}
ret = Pulp::Task.find(uuids)
ret.each do |pulp_task|
PulpTaskStatus.dump_state(pulp_task, TaskStatus.find_by_uuid(pulp_task["id"]))
unless ids.nil? || ids.empty?
uuids = TaskStatus.select(:uuid).where(:id => ids).collect{|t| t.uuid}
ret = Pulp::Task.find(uuids)
ret.each do |pulp_task|
PulpTaskStatus.dump_state(pulp_task, TaskStatus.find_by_uuid(pulp_task["id"]))
end
end
end

Expand Down

0 comments on commit 541174b

Please sign in to comment.