diff --git a/core/lib/utils/mail/mail_address.dart b/core/lib/utils/mail/mail_address.dart index ad2b1f4db7..276b701755 100644 --- a/core/lib/utils/mail/mail_address.dart +++ b/core/lib/utils/mail/mail_address.dart @@ -166,6 +166,8 @@ class MailAddress with EquatableMixin { } String strictUrlEncode(String input) { + // cannot use Uri.encodeComponent because it is meant to be compliant with RFC2396 + // eg `-_.!~*'()` are not encoded (but we want them to) final StringBuffer encoded = StringBuffer(); for (int codeUnit in utf8.encode(input)) {