mirror of
https://github.com/discourse/discourse.git
synced 2024-11-29 11:09:34 +08:00
FIX: Suppress error when acccess is invalid.
This commit is contained in:
parent
389e1d0bd5
commit
1cb09aec49
|
@ -9,5 +9,7 @@ class HomePageConstraint
|
||||||
provider = Discourse.current_user_provider.new(request.env)
|
provider = Discourse.current_user_provider.new(request.env)
|
||||||
homepage = provider.current_user ? SiteSetting.homepage : SiteSetting.anonymous_homepage
|
homepage = provider.current_user ? SiteSetting.homepage : SiteSetting.anonymous_homepage
|
||||||
homepage == @filter
|
homepage == @filter
|
||||||
|
rescue Discourse::InvalidAccess
|
||||||
|
false
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue
Block a user