Conform more of the codebase to strictNullChecks (#11134)

This commit is contained in:
Michael Telatynski
2023-06-27 17:39:56 +01:00
committed by GitHub
parent 3d886de5b0
commit e1cad41bc3
15 changed files with 44 additions and 36 deletions

View File

@@ -700,7 +700,7 @@ export default class ScrollPanel extends React.Component<IProps> {
const trackedNode = this.getTrackedNode();
if (trackedNode) {
const newBottomOffset = this.topFromBottom(trackedNode);
const bottomDiff = newBottomOffset - scrollState.bottomOffset;
const bottomDiff = newBottomOffset - (scrollState.bottomOffset ?? 0);
this.bottomGrowth += bottomDiff;
scrollState.bottomOffset = newBottomOffset;
const newHeight = `${this.getListHeight()}px`;