Skip to content
Snippets Groups Projects
Commit babdf45a authored by Douglas Barbosa Alexandre's avatar Douglas Barbosa Alexandre
Browse files

Use IssuesFinder instead of project.issues.visible_to_user

parent 4de6799e
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -29,7 +29,11 @@ module Projects
private
 
def issue
@issue ||= project.issues.visible_to_user(current_user).find_by!(iid: params[:id])
@issue ||=
IssuesFinder.new(current_user, project_id: project.id, state: 'all')
.execute
.where(iid: params[:id])
.first!
end
 
def authorize_read_issue!
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment