Hi all,
we're experiencing a crash with the new version of the library (1.26.0) with the SkeletonAppearance with textLineHeight = .relativeToFont. The app crashes with "NSMutableRLEArray objectAtIndex:effectiveRange:: Out of bounds" when calling layoutSkeletonIfNeeded if the UILabel to Skeletonize has nil text or is empty.
What type of issue is this? (place an x in one of the [ ])
[x ] bug
[ ] enhancement (feature request)
[ ] question
[ ] documentation related
[ ] discussion
Requirements (place an x in each of the [ ])
[ x] I've read and understood the Contributing guidelines and have done my best effort to follow them.
Description
Hi all, we're experiencing a crash with the new version of the library (1.26.0) with the SkeletonAppearance with textLineHeight = .relativeToFont. The app crashes with "NSMutableRLEArray objectAtIndex:effectiveRange:: Out of bounds" when calling layoutSkeletonIfNeeded if the UILabel to Skeletonize has nil text or is empty.
What type of issue is this? (place an
x
in one of the[ ]
)Requirements (place an
x
in each of the[ ]
)Bug Report
Filling out the following details about bugs will help us solve your issue sooner.
SkeletonView Environment:
SkeletonView version: 1.26.0 Xcode version: 13.2.1 **Swift version: Swift 5.5.2
Steps to reproduce:
Please replace this with the steps to reproduce the behavior.
Expected result:
The app shouldn't crash.
Actual result:
The app crashes with "NSMutableRLEArray objectAtIndex:effectiveRange:: Out of bounds"
Attachments:
I suggest this edit at line 93 of SkeletonTextNode.swift: