-
Notifications
You must be signed in to change notification settings - Fork 144
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
Problem calling PATCH on an OnlineMeeting #1484
Problem calling PATCH on an OnlineMeeting #1484
Comments
Hi @gkotsinos ,thank you for trying out the SDK, I am currently looking into the issue. In the meantime, could you please provide the version of the SDK you are using and the code you are trying to run(if possible). |
Hi, thanks for the quick response! I can't share the exact code but you should be able to easilly reproduce it. Working on an existing OnlineMeeting:
this should be enough to catch it. Just FYI, I haven't run this code it might have issues! I edited my initial comment with a simple solution that kinda highlights the issue as well. |
Hello, forgot to mention, I' m using the latest version of the SDK, Release 2.3.0 |
Hi @gkotsinos, thanks for providing additional information. |
Hi @gkotsinos ,the issue is now resolved. |
Hello,
as stated, I am trying to patch an Microsoft\Graph\Generated\Models\OnlineMeeting model. The error I am getting is that I am sending a property that isn't allowed to get PATCHed. After some debugging I figured out that although during the instantiation of my OnlineMeeting object I am only filling the attendees property, the body of the request ends up being this:
{"@odata.type":"#microsoft.graph.onlineMeeting","attendeeReport":null,"participants":{"attendees":[{"upn":"[email protected]"}]}}
From what I understand the
attendeeReport
property should not end up in the request body since I am not setting it, and I have confirmed that is the issue since sending the same request without the property works fine.Also as defined in the relevant documentation this property is not even in the list of options that are updateable ( https://learn.microsoft.com/en-us/graph/api/onlinemeeting-update?view=graph-rest-1.0&tabs=http#request-body )
EDIT: I can successfully solve the issue with this simplistic approach confirming the issue:
Within
Microsoft\Graph\Generated\Models\OnlineMeeting
change this line:
$writer->writeBinaryContent('attendeeReport', $this->getAttendeeReport());
to this line:
if (!empty($this->getAttendeeReport())) { $writer->writeBinaryContent('attendeeReport', $this->getAttendeeReport()); }
The text was updated successfully, but these errors were encountered: