From f9f99fea7e395b9e0e1fc7f80506372cfa5973b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=91=B1=E5=91=B1=E5=91=B1?= Date: Sat, 7 Oct 2023 17:29:26 +0800 Subject: [PATCH] fix bug --- app/models/glcc_medium_term_examine_material.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/models/glcc_medium_term_examine_material.rb b/app/models/glcc_medium_term_examine_material.rb index b5f6e441e..56e78c29e 100644 --- a/app/models/glcc_medium_term_examine_material.rb +++ b/app/models/glcc_medium_term_examine_material.rb @@ -36,8 +36,8 @@ class GlccMediumTermExamineMaterial < ActiveRecord::Base unless pull_index == 5 state << 2 end - - project = Project.find_by(identifier: url_array[4]) + user = User.find_by(login: url_array[3]) + project = Project.find_by(identifier: url_array[4], user_id:user.try(:id)) pr = PullRequest.where(project:project, gitea_number:url_array[6]) unless pr.present?