-
Notifications
You must be signed in to change notification settings - Fork 93
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
Missing Property Declarations give "Field accessed via magic method" warnings #358
Comments
Hi @JDubDev! I'm looking into your issue. I can confirm that there is no I noticed that it's a It would help me confirm and fix your issue if you let me know which version of the Recurly library you're using as well as what IDE you're seeing the error(s) in so I can try to recreate the issue. Thanks! |
I'm using composer to manage and have it set to
And go figure, I ran an update earlier today and missed that the warning on current_period_ends_at dropped off. So that one is good to go. The UUID missing is the only one I'm still getting. My IDE, by the way, is PHPStorm by Jetbrains. Latest release version. I did a quick check through my project for any Magic method warnings and found one other. It looks like in addition to the uuid missing from \Recurly_Subscription, plan is also missing. My first thought was that that should be a reference to \Recurly_Plan but the two aren't the same. It looks like maybe a stub object is needed for \Recurly_Subscription->plan that contains just plan_code and name. I did notice that, at least in this latest version, the \Recurly_Plan object has duplicate plan_code and name property declarations. I'd be happy to clean these up on a fork and then submit a pull request if that's preferred. |
Sure, that would be great! I'll review your PR and merge it in as long as there are no issues. Thanks 🙂 |
I just realized that this relates to #277. I'm going to try to get to that in the next couple weeks, and when I open that PR, ideally it will fix this as well. It will be nice to close out two issues with one PR. |
Specifically, Recurly_Subscription is missing property declarations for the following (there may be others but these are the two that I use frequently and my IDE throws the warning)
Both are included in the API documentation as properties of the response object and I've used both fields in code.
https://dev.recurly.com/docs/lookup-subscription-details
The text was updated successfully, but these errors were encountered: