obs-websocket-js icon indicating copy to clipboard operation
obs-websocket-js copied to clipboard

Crash in swipeColor function at the very beginning of swiping gesture

Open nadyapost opened this issue 5 years ago • 1 comments

Crash occurs at the beginning of swipe gesture - when very slowly start dragging a cell to the right or to the left.

Screen Shot 2020-09-15 at 2 23 21 pm Screen Shot 2020-09-15 at 2 15 43 pm

nadyapost avatar Sep 15 '20 04:09 nadyapost

I got the same problem but discovered that it is this code from the example code which introduceg this crash:

cell.defaultColor = tableView.backgroundView?.backgroundColor

The example code should be updated.

In my case the defaultcolor becomes nil and since its being forceunwrapped in SwipyCell it will crash.

SwipyCell { public var defaultColor: UIColor! }

The fix is to make sure cell.defaultColor has a real value.

knutigro avatar Nov 03 '20 12:11 knutigro