mirror of
https://github.com/zoriya/react-native-svg.git
synced 2026-06-04 07:25:53 +00:00
fix: remove using pattern matching in FilterView (#2354)
# Summary Closes #2347 Fixed a problem with building an Android app, pattern matching threw an error when we tried to build an Android app. [Repository](https://github.com/bohdanprog/react-native-svg-error-pattern-matching) to reproduce that error. ## Test Plan We can easily check that build the app. ### What are the steps to reproduce (after prerequisites)? build the app without that fix. ## Compatibility | OS | Implemented | | ------- | :---------: | | Android | ✅ |
This commit is contained in:
@@ -80,7 +80,8 @@ class FilterView extends DefinitionView {
|
|||||||
|
|
||||||
for (int i = 0; i < getChildCount(); i++) {
|
for (int i = 0; i < getChildCount(); i++) {
|
||||||
View node = getChildAt(i);
|
View node = getChildAt(i);
|
||||||
if (node instanceof FilterPrimitiveView currentFilter) {
|
if (node instanceof FilterPrimitiveView) {
|
||||||
|
FilterPrimitiveView currentFilter = (FilterPrimitiveView) node;
|
||||||
res = currentFilter.applyFilter(mResultsMap, res);
|
res = currentFilter.applyFilter(mResultsMap, res);
|
||||||
String resultName = currentFilter.getResult();
|
String resultName = currentFilter.getResult();
|
||||||
if (resultName != null) {
|
if (resultName != null) {
|
||||||
|
|||||||
Reference in New Issue
Block a user