Merge pull request #3407 from NARKOZ/patch-1

use convenient method to check for empty project repo
This commit is contained in:
Dmitriy Zaporozhets 2013-03-26 23:28:07 -07:00
commit a31fe1a63f

View file

@ -57,11 +57,11 @@ class ProjectsController < ProjectResourceController
respond_to do |format|
format.html do
if @project.repository && !@project.repository.empty?
if @project.empty_repo?
render "projects/empty"
else
@last_push = current_user.recent_push(@project.id)
render :show
else
render "projects/empty"
end
end
format.js