Project

General

Profile

Patch #14109 ยป changesets.patch

D G, 2013-05-21 11:30

View differences:

app/views/issues/show.api.rsb (Arbeitskopie)
39 39
  end if include_in_api_response?('relations') && @relations.present?
40 40

  
41 41
  api.array :changesets do
42
    @issue.changesets.each do |changeset|
42
    @issue.changesets.visible.all.each do |changeset|
43 43
      api.changeset :revision => changeset.revision do
44 44
        api.user(:id => changeset.user_id, :name => changeset.user.name) unless changeset.user.nil?
45 45
        api.comments changeset.comments
46 46
        api.committed_on changeset.committed_on
47 47
      end
48 48
    end
49
  end if include_in_api_response?('changesets') && User.current.allowed_to?(:view_changesets, @project)
49
  end if include_in_api_response?('changesets')
50 50

  
51 51
  api.array :journals do
52 52
    @journals.each do |journal|
    (1-1/1)