Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Changelog

## v5.0.3
- fix(policy): harden authorization for plan resources [#3613](https://github.com/DMPRoadmap/roadmap/pull/3613)

## v5.0.2
- Bump Ruby to v3.1.4 and use `.ruby-version` in CI
- [#3566](https://github.com/DMPRoadmap/roadmap/pull/3566)
Expand Down
4 changes: 2 additions & 2 deletions app/controllers/contributors_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ class ContributorsController < ApplicationController

# GET /plans/:plan_id/contributors
def index
authorize @plan
authorize @plan, :show?
@contributors = @plan.contributors
end

# GET /plans/:plan_id/contributors/new
def new
authorize @plan
authorize @plan, :edit?
default_org = @plan.org.present? ? @plan.org : current_user.org
@contributor = Contributor.new(plan: @plan, org: default_org)
end
Expand Down
Loading