-
Notifications
You must be signed in to change notification settings - Fork 61
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
NoMethodError: undefined method `has_key?' for nil:NilClass #147
Comments
It doesn't seem to like the JSON.pretty_generate(to_hash, opts) if I'm reading it correctly
|
I am having the same issue. We are running ruby version 3.0.1, could that be a potential cause of this? If I make a call to |
@trazaq, for now I was able to work around this by overriding the I am using the gem in a rails app so I was able to create a file at module FHIR
module Json
def to_json(opts = {})
super
end
end
end That has me going for now, but I am not sure what the implications of doing something like that might be for your code, so YMMV. |
I appreciate the authors of this gem! It does indeed come in handy! Ah! That's one way of going about it! Anyway, I'm not using this gem's internal HTTP client. I construct the models and use HTTParty to do the actual sending/receiving of data as my HTTP client. Works well so far. Just have to remember to convert your model to a hash, then to json in my case before sending it to the receiving system. |
@antonivanopoulos we are using oj in the application where I was running into this issue. That is probably the cause for me. |
HI,
Thanks for this gem!
I'm getting a error after following the transaction example in the README.
Any ideas?
The text was updated successfully, but these errors were encountered: