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

Create an Attachment constructor that takes a URI and a constructor that takes a string

Open rianjs opened this issue 8 years ago • 0 comments

v2's Attachment constructor takes a string, which it uses as a Uri. Consider creating an nth Attachment constructor that takes a Uri, and uses it as a URI as the spec intends.

In addition, it might be helpful to retain the string constructor, and auto-convert that a base64-encoded payload.

Caveats: this could create subtle bugs in existing applications. Maybe in the string constructor, we could add a Uri.TryParse call that calls the Uri-based constructor if the string looks like a URL as a workaround.

rianjs avatar Apr 28 '17 14:04 rianjs