Skip to content
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 #4

Open
cseelus opened this issue Aug 13, 2018 · 1 comment
Open

NoMethodError #4

cseelus opened this issue Aug 13, 2018 · 1 comment

Comments

@cseelus
Copy link

cseelus commented Aug 13, 2018

Feature set of this gem looks really nice, thanks for creating it.

When using Solar.position as per the README, I receive a NoMethodError: undefined method ajd for 2014-03-22 12:00:00 UTC:Time.

Is there a specific Ruby version required?

Edit: I'm using the most recent Ruby version (2.5.1p57) via rbenv on macOS 10.14.

@jhulstedt
Copy link

I don't think the version of ruby matters. I think there is an error on line 22 of support.rb. The time object first has to transformed to .utc then .to_datetime then to .ajd
Original code line 22:
t.to_datetime.utc.ajd # This was the original code and gave errors with the .ajd
Change to this:
t.utc.to_datetime.ajd # Change to this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants