Skip to content

Commit feaf9a4

Browse files
author
Enguerrand ARMINJON WINDOWS
committed
[vector_graphics_compiler] fix-null-exception
1 parent 2c8f226 commit feaf9a4

File tree

3 files changed

+9
-2
lines changed

3 files changed

+9
-2
lines changed

packages/vector_graphics_compiler/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 1.1.13
2+
3+
* Fixes an issue where empty tag could throw and broke SVG.
4+
15
## 1.1.12
26

37
* Transfers the package source from https://github.com/dnfield/vector_graphics

packages/vector_graphics_compiler/lib/src/svg/parser.dart

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -895,7 +895,10 @@ class SvgParser {
895895
return false;
896896
}
897897
final ParentNode parent = _parentDrawables.last.drawable;
898-
final Path path = pathFunc(this)!;
898+
final Path? path = pathFunc(this);
899+
if (path == null) {
900+
return false;
901+
}
899902
final PathNode drawable = PathNode(path, _currentAttributes);
900903
checkForIri(drawable);
901904

packages/vector_graphics_compiler/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+
55
# See https://github.com/flutter/flutter/issues/157626 before publishing a new
66
# version.
77
publish_to: none
8-
version: 1.1.12
8+
version: 1.1.13
99

1010
executables:
1111
vector_graphics_compiler:

0 commit comments

Comments
 (0)