forked from shadowfacts/Tusker
Fix crash when profile screen disappears
This commit is contained in:
parent
d1c45a87e6
commit
cdffda5593
|
@ -117,7 +117,9 @@ class TimelineLikeTableViewController<Item>: EnhancedTableViewController, Refres
|
||||||
}
|
}
|
||||||
|
|
||||||
private func pruneOffscreenRows() {
|
private func pruneOffscreenRows() {
|
||||||
guard let lastVisibleRow = lastLastVisibleRow else {
|
guard let lastVisibleRow = lastLastVisibleRow,
|
||||||
|
// never remove the last section
|
||||||
|
sections.count - headerSectionsCount() > 1 else {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
let lastSectionIndex = sections.count - 1
|
let lastSectionIndex = sections.count - 1
|
||||||
|
|
Loading…
Reference in New Issue