Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fix scoping to be more definite

  • Loading branch information...
commit 05c86c8e1935dfa3cca887907d5e14f0fa4268ac 1 parent 608d6c8
@seejohnrun authored
Showing with 3 additions and 4 deletions.
  1. +1 −3 lib/apns/connector.rb
  2. +2 −1  lib/apns/notification.rb
View
4 lib/apns/connector.rb
@@ -47,7 +47,7 @@ def feedback
apns_feedback
end
- protected
+ private
def open_connection
check_pem!
@@ -79,8 +79,6 @@ def feedback_connection
[sock, ssl]
end
- private
-
def check_pem!
raise "the path to your pem file is not set. (apns.pem = /path/to/cert.pem)" unless self.pem
raise "the path to your pem file does not exist!" unless pem_exists?
View
3  lib/apns/notification.rb
@@ -1,5 +1,6 @@
module APNS
class Notification
+
attr_accessor :device_token, :alert, :badge, :sound, :other
def initialize(device_token, message)
@@ -23,7 +24,7 @@ def packaged_notification
end
def packaged_token
- [device_token.gsub(/[\s|<|>]/,'')].pack('H*')
+ [device_token.gsub(/[\s|<|>]/, '')].pack('H*')
end
def packaged_message
Please sign in to comment.
Something went wrong with that request. Please try again.