From 1d2ea48812aee74b75076a65b5847b69880ac48a Mon Sep 17 00:00:00 2001 From: xxq250 Date: Tue, 4 Apr 2023 15:30:28 +0800 Subject: [PATCH] =?UTF-8?q?fixed=20bot=E5=AE=89=E8=A3=85=E4=BB=93=E5=BA=93?= =?UTF-8?q?=E5=88=97=E8=A1=A8=EF=BC=8C=E4=B8=8Egithub=E5=B7=AE=E5=BC=82?= =?UTF-8?q?=EF=BC=8C=E6=89=80=E4=BB=A5=E5=8F=96=E5=AE=89=E8=A3=85=E7=94=A8?= =?UTF-8?q?=E6=88=B7=E5=92=8Cbot=E5=AF=B9=E5=BA=94=E6=89=80=E6=9C=89?= =?UTF-8?q?=E7=9A=84=E4=BB=93=E5=BA=93?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/installations_controller.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/controllers/installations_controller.rb b/app/controllers/installations_controller.rb index a08174022..a87916271 100644 --- a/app/controllers/installations_controller.rb +++ b/app/controllers/installations_controller.rb @@ -16,8 +16,10 @@ class InstallationsController < ApplicationController end def repositories + # 与github差异,所以取安装用户和bot对应所有的仓库 + install_bot = BotInstall.find params[:id] bot = Bot.find_by(uid: current_user.id) - @install_bots = BotInstall.where(bot_id: bot.id).where(:installer_id => bot.owner_id) + @install_bots = BotInstall.where(bot_id: bot.id).where(:installer_id => install_bot.installer_id) end def update_secret