File tree Expand file tree Collapse file tree 3 files changed +17
-4
lines changed Expand file tree Collapse file tree 3 files changed +17
-4
lines changed Original file line number Diff line number Diff line change
1
+ ## 1.0.4
2
+
3
+ - Allow ` package:yaml ` ` v3.x ` .
4
+
1
5
## 1.0.3
2
6
3
7
- Require at least Dart ` 2.7.0 ` .
Original file line number Diff line number Diff line change @@ -27,8 +27,17 @@ T checkedYamlDecode<T>(
27
27
allowNull ?? = false ;
28
28
YamlNode yaml;
29
29
30
+ Uri sourceUri;
31
+ if (sourceUrl == null ) {
32
+ // noop
33
+ } else if (sourceUrl is Uri ) {
34
+ sourceUri = sourceUrl;
35
+ } else {
36
+ sourceUri = Uri .parse (sourceUrl as String );
37
+ }
38
+
30
39
try {
31
- yaml = loadYamlNode (yamlContent, sourceUrl: sourceUrl );
40
+ yaml = loadYamlNode (yamlContent, sourceUrl: sourceUri );
32
41
} on YamlException catch (e) {
33
42
throw ParsedYamlException .fromYamlException (e);
34
43
}
Original file line number Diff line number Diff line change 1
1
name : checked_yaml
2
- version : 1.0.3
2
+ version : 1.0.4
3
3
description : >-
4
4
Generate more helpful exceptions when decoding YAML documents using
5
5
package:json_serializable and package:yaml.
6
- homepage : https://github.com/google/json_serializable.dart
6
+ repository : https://github.com/google/json_serializable.dart
7
7
environment :
8
8
sdk : ' >=2.7.0 <3.0.0'
9
9
10
10
dependencies :
11
11
json_annotation : ' >=2.2.0 <5.0.0'
12
12
source_span : ^1.0.0
13
- yaml : ^ 2.1.13
13
+ yaml : ' >= 2.1.13 <4.0.0 '
14
14
15
15
dev_dependencies :
16
16
build_runner : ^1.0.0
You can’t perform that action at this time.
0 commit comments