Commit 11a1d87
fix: handle error when defining a nil reference (#2717)
# Summary
That PR helped to solve issue #2715
This issue arises on the iOS platform because
`NSMutableDictionary<NSString *, RNSVGNode *>` does not allow nil keys
or values. On Android, however, the `Map<String, VirtualView>`
implementation does allow null keys, which prevents this issue from
occurring there.
To address the iOS issue, we handle nil values for elements such as
`clipPaths, templates, painters, markers, masks, and filters`. Managing
`nil` values in `RNSVGSvgView.mm` is practical because the `define*`
method is used in multiple locations.
---------
Co-authored-by: Jakub Grzywacz <[email protected]>
Co-authored-by: Jakub Grzywacz <[email protected]>1 parent 62d496b commit 11a1d87
1 file changed
+18
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
402 | 402 | | |
403 | 403 | | |
404 | 404 | | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
405 | 408 | | |
406 | 409 | | |
407 | 410 | | |
| |||
415 | 418 | | |
416 | 419 | | |
417 | 420 | | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
418 | 424 | | |
419 | 425 | | |
420 | 426 | | |
| |||
428 | 434 | | |
429 | 435 | | |
430 | 436 | | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
431 | 440 | | |
432 | 441 | | |
433 | 442 | | |
| |||
441 | 450 | | |
442 | 451 | | |
443 | 452 | | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
444 | 456 | | |
445 | 457 | | |
446 | 458 | | |
| |||
454 | 466 | | |
455 | 467 | | |
456 | 468 | | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
457 | 472 | | |
458 | 473 | | |
459 | 474 | | |
| |||
467 | 482 | | |
468 | 483 | | |
469 | 484 | | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
470 | 488 | | |
471 | 489 | | |
472 | 490 | | |
| |||
0 commit comments