Closed mylescc closed 9 years ago
Hey Miles,
Thank you for your pull request.
Could you give an example on why you'd want this and why not use something like the following?
client = MessageBird::Client.new(ENV['MESSAGE_BIRD_ACCESS_KEY'])
Hey,
I guess its just to keep code clean. Other clients like yours that I've used allow you to just initialise the client like:
client = MessageBird::Client.new
for example: https://github.com/amro/gibbon/blob/master/lib/gibbon/api.rb and https://github.com/timcraft/nexmo/blob/master/lib/nexmo.rb
This update at least gives you the option to use both.
Hey, do you think you might merge this PR? I'm about to put our code that uses the message bird gem into production, but I'm using my fork at the moment, but would obviously prefer to use yours, just to make sure its always up to date. Cheers!
Hey Miles,
Sure, but before I do, could you change the environment variable from MESSAGE_BIRD_ACCESS_KEY to MESSAGEBIRD_ACCESS_KEY?
Awesome thanks! Done!
Allowing the access_token to be loaded directly from an env file, rather than always having to pass it in each time.