# preload users, tags and comments, and render result
@changesets = changesets.preload(:user, :changeset_tags, :comments)
# preload users, tags and comments, and render result
@changesets = changesets.preload(:user, :changeset_tags, :comments)
@comments = @comments.unscope(:where => :visible) if params[:show_hidden_comments].presence && can?(:restore, ChangesetComment)
@comments = @comments.includes(:author)
end
@comments = @comments.unscope(:where => :visible) if params[:show_hidden_comments].presence && can?(:restore, ChangesetComment)
@comments = @comments.includes(:author)
end
check_changeset_consistency(@changeset, current_user)
@changeset.update_from(new_changeset, current_user)
check_changeset_consistency(@changeset, current_user)
@changeset.update_from(new_changeset, current_user)
changesets.where("closed_at >= ? and created_at <= ?", from, to)
else
# if there is no comma, assume its a lower limit on time
changesets.where("closed_at >= ? and created_at <= ?", from, to)
else
# if there is no comma, assume its a lower limit on time
end
# stupid Time seems to throw both of these for bad parsing, so
# we have to catch both and ensure the correct code path is taken.
end
# stupid Time seems to throw both of these for bad parsing, so
# we have to catch both and ensure the correct code path is taken.