ical.net icon indicating copy to clipboard operation
ical.net copied to clipboard

Only override ProductId/Version if they arent already provided

Open CreepyGnome opened this issue 7 years ago • 2 comments

Fix for https://github.com/rianjs/ical.net/issues/408

CreepyGnome avatar Jul 17 '18 16:07 CreepyGnome

This change is safe. I am not sure I understand your concerns.,

The issue is that ProdId and Version where being overwritten and forced to the iCal.net values. The only change here is if they are not set it will continue to work as it has been. The allows people to set the values without having to worry about them being overwritten. Which is the source of the issue for us, and how I understood the bug #408 have you read that?

This serialization is serializing from an object to a string. Also, not sure why it matters if it came from code or was deserialized from another source.

Anyone who is using the Internet Calendar format as specified by its RFC should know how and why to set ProdId and Version and that they should ensure it is set before serializing to a string. If they don't then they get the Ical.net defaults.

I will leave it to @rianjs to review as it does resolve the bug that is currently open and which is one I have had to work around and would like to remove my workaround.

CreepyGnome avatar Jul 17 '18 20:07 CreepyGnome

Any news on this?

randbrown avatar May 28 '21 16:05 randbrown