| Index: lib/uri/encode_decode.dart
|
| diff --git a/lib/uri/encode_decode.dart b/lib/uri/encode_decode.dart
|
| index 511bce05dfdb8bf5a56df64fc72fc640e6b399b7..6338518a4a5a290b2dbfe959912ccbbeb07ffbc4 100644
|
| --- a/lib/uri/encode_decode.dart
|
| +++ b/lib/uri/encode_decode.dart
|
| @@ -90,7 +90,7 @@ String _uriEncode(String canonical, String text) {
|
| // convert the pair to a U+10000 codepoint
|
| ch = 0x10000 + ((ch-0xD800) << 10) + (nextCh - 0xDC00);
|
| } else {
|
| - throw new IllegalArgumentException('Malformed URI');
|
| + throw new ArgumentError('Malformed URI');
|
| }
|
| }
|
| for (int codepoint in codepointsToUtf8([ch])) {
|
| @@ -132,7 +132,7 @@ String _uriDecode(String text) {
|
| codepoints.clear();
|
| while (ch == '%') {
|
| if (++i > text.length - 2) {
|
| - throw new IllegalArgumentException('Truncated URI');
|
| + throw new ArgumentError('Truncated URI');
|
| }
|
| codepoints.add(_hexCharPairToByte(text, i));
|
| i += 2;
|
|
|