From 74a9743bcc95b835bb701a4286cdeafb090784ed Mon Sep 17 00:00:00 2001 From: yystopf Date: Tue, 7 Sep 2021 15:17:52 +0800 Subject: [PATCH] fix: annoymous user visit project --- app/controllers/application_controller.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index 6848fffaa..11ea87dd9 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -762,10 +762,10 @@ class ApplicationController < ActionController::Base if @project and current_user.can_read_project?(@project) logger.info "###########: has project and can read project" @project - elsif @project && current_user.is_a?(AnonymousUser) - logger.info "###########:This is AnonymousUser" - @project = nil if !@project.is_public? - render_forbidden and return + # elsif @project && current_user.is_a?(AnonymousUser) + # logger.info "###########:This is AnonymousUser" + # @project = nil if !@project.is_public? + # render_forbidden and return else logger.info "###########:project not found" @project = nil