-
-
Notifications
You must be signed in to change notification settings - Fork 87
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
No async task available #44
Comments
Either: Async do
connection.accounts.first
ensure
connection.close
end or: Cloudflare.connect(key: c[:key], email: c[:email]) do |connection|
connection.accounts.first
end |
If you want the result of that block, append Cloudflare.connect(key: c[:key], email: c[:email]) do |connection|
account = connection.accounts.first
# do something with account
end |
Ah ha - thank you. I guess the README is lagging behind slightly? |
Yeah do you have time to submit a PR to update the README? |
Sure, but maybe in a few weeks... |
Out of interest, why make this change? What was wrong with the simple rest-client before? |
In no particular order:
If you want to use 3.x nothing is stopping you, and if you want to maintain 3.x I will happily help with that. |
Am I doing something wrong with this example? Do I need to initialize Async somehow?
Ruby 2.5.3, Rails 5.2.2, Cloudflare 4.0.0, FreeBSD 11
If I try using
rails runner test.rb
, I get a backtrace:The text was updated successfully, but these errors were encountered: