From 9edd49a44d06c40f552ed153150b6b3cf074c139 Mon Sep 17 00:00:00 2001 From: Zeneixe Date: Thu, 2 Nov 2023 11:57:55 +0100 Subject: [PATCH 1/4] Search for the Rails module in the root namespace --- lib/view_component/base.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/view_component/base.rb b/lib/view_component/base.rb index 0bdee95af..f5a91ac11 100644 --- a/lib/view_component/base.rb +++ b/lib/view_component/base.rb @@ -219,7 +219,7 @@ def helpers @__vc_helpers ||= __vc_original_view_context || controller.view_context end - if Rails.env.development? || Rails.env.test? + if ::Rails.env.development? || ::Rails.env.test? def method_missing(method_name, *args) # rubocop:disable Style/MissingRespondToMissing super rescue => e # rubocop:disable Style/RescueStandardError From 4fcf3f0a00947aa9b6b6f4f96daf3bae2977ad84 Mon Sep 17 00:00:00 2001 From: Zeneixe Date: Fri, 3 Nov 2023 09:56:28 +0100 Subject: [PATCH 2/4] Update CHANGELOG --- docs/CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 4af977c04..9ec0b3b40 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -10,6 +10,8 @@ nav_order: 5 ## main +* Fix bug where the `Rails` module wasn't being searched from the root namespace + * Fix bug where `#with_request_url`, set the incorrect `request.fullpath`. *Nachiket Pusalkar* From b3f53f988fe22984da036a257eadef25b774c5a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zen=C3=A9ixe?= <1379179+Zeneixe@users.noreply.github.com> Date: Fri, 3 Nov 2023 13:37:06 +0100 Subject: [PATCH 3/4] Update docs/CHANGELOG.md Co-authored-by: Hans Lemuet --- docs/CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 9ec0b3b40..4b7a2db15 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -10,7 +10,7 @@ nav_order: 5 ## main -* Fix bug where the `Rails` module wasn't being searched from the root namespace +* Fix bug where the `Rails` module wasn't being searched from the root namespace. * Fix bug where `#with_request_url`, set the incorrect `request.fullpath`. From 19d27be99bc453a5e00d81b4e4ec349081fce887 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zen=C3=A9ixe?= <1379179+Zeneixe@users.noreply.github.com> Date: Fri, 3 Nov 2023 18:38:51 +0100 Subject: [PATCH 4/4] Update docs/CHANGELOG.md Co-authored-by: Hans Lemuet --- docs/CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 4b7a2db15..c9b233a5e 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -12,6 +12,8 @@ nav_order: 5 * Fix bug where the `Rails` module wasn't being searched from the root namespace. + *Zenéixe* + * Fix bug where `#with_request_url`, set the incorrect `request.fullpath`. *Nachiket Pusalkar*