Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

RAILS_ENV is now deprecated

  • Loading branch information...
commit 563f0bc298a87246137b67291d1bf3fc101a8319 1 parent ca98c7c
Philippe Van Eerdenbrugghe authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  lib/apn_on_rails/app/models/apn/app.rb
View
2  lib/apn_on_rails/app/models/apn/app.rb
@@ -8,7 +8,7 @@ class APN::App < APN::Base
has_many :unsent_group_notifications, :through => :groups
def cert
- (RAILS_ENV == 'production' ? apn_prod_cert : apn_dev_cert)
+ (Rails.env == 'production' ? apn_prod_cert : apn_dev_cert)
end
# Opens a connection to the Apple APN server and attempts to batch deliver

1 comment on commit 563f0bc

@mattconnolly

Rails.env.production? is preferred as it removes potential mistaken occurrences of = instead of ==.

Please sign in to comment.
Something went wrong with that request. Please try again.