lib/line_notify/client.rb in line_notify-0.1.0 vs lib/line_notify/client.rb in line_notify-1.0.0

- old
+ new

@@ -4,11 +4,11 @@ module LineNotify class Client URI = URI.parse("https://notify-api.line.me/api/notify") def initialize(access_token) - @access_token = (ENV['LINE_ACCESS_TOKEN'] || access_token) + @access_token = (access_token || ENV['LINE_ACCESS_TOKEN']) end def send(options) request = create_request(options) Net::HTTP.start(URI.hostname, URI.port, use_ssl: URI.scheme == "https") do |req| @@ -22,6 +22,6 @@ request["Authorization"] = "Bearer #{@access_token}" request.set_form_data(options) request end end -end \ No newline at end of file +end