Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Rails.env.local? #46786

Merged
merged 3 commits into from Dec 21, 2022
Merged

Add Rails.env.local? #46786

merged 3 commits into from Dec 21, 2022

Conversation

dhh
Copy link
Member

@dhh dhh commented Dec 21, 2022

So many checks against Rails.env is whether we're running test or development, so combine into just one.

Before:

if Rails.env.development? || Rails.env.test?

After:

if Rails.env.local?

So many checks against Rails.env is whether we're running test or development, so combine into just one.
Now that we have it as a combined predicate for dev + test.
@dhh dhh merged commit 47eaf88 into main Dec 21, 2022
@dhh dhh deleted the add-rails-env-local branch December 21, 2022 14:38
Gerg added a commit to cloudfoundry/cloud_controller_ng that referenced this pull request Jan 3, 2024
- Rails introduced `Rails.env.local?`
  (rails/rails#46786) with a different
  implementation than what we were using in stagings_controller.rb. The
  previous implementation (metaprogramming?) was introduced for the
  `scripts/cf-release/run-local-cc.sh` script, which appears to be
  non-functional these days.

[#3438]
johha pushed a commit to cloudfoundry/cloud_controller_ng that referenced this pull request Feb 1, 2024
- Rails introduced `Rails.env.local?`
  (rails/rails#46786) with a different
  implementation than what we were using in stagings_controller.rb. The
  previous implementation (metaprogramming?) was introduced for the
  `scripts/cf-release/run-local-cc.sh` script, which appears to be
  non-functional these days.

[#3438]
@olimart olimart mentioned this pull request Feb 2, 2024
4 tasks
glaszig added a commit to glaszig/exception_notification that referenced this pull request Mar 12, 2024
Rails.env.local? is available since 7.1, rails/rails#46786
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant