修复:疑修不存在

This commit is contained in:
yystopf 2025-05-22 14:13:50 +08:00
parent 78c5458bb8
commit ce5d5a88ba
2 changed files with 2 additions and 2 deletions

View File

@ -31,7 +31,7 @@ class Api::Pm::BaseController < ApplicationController
def load_issue
# return render_parameter_missing if params[:pm_project_id].blank?
@issue = Issue.issue_issue.where(pm_project_id: params[:pm_project_id]).find_by_id(params[:issue_id])
@issue = Issue.issue_issue.find_by_id(params[:issue_id])
render_not_found('疑修不存在!') if @issue.blank?
end
# 具有对仓库的管理权限

View File

@ -285,7 +285,7 @@ class Api::Pm::IssuesController < Api::Pm::BaseController
def load_issue
# return render_parameter_missing if params[:pm_project_id].blank?
@issue = Issue.issue_issue.where(pm_project_id: params[:pm_project_id]).find_by_id(params[:id])
@issue = Issue.issue_issue.find_by_id(params[:id])
render_not_found('疑修不存在!') if @issue.blank?
end