diff --git a/src/components/scroll-region.cjsx b/src/components/scroll-region.cjsx index 8807576c0..d44b8050a 100644 --- a/src/components/scroll-region.cjsx +++ b/src/components/scroll-region.cjsx @@ -210,7 +210,7 @@ class ScrollRegion extends React.Component scrollToRect: (rect, {position, settle, done} = {}) -> if rect instanceof Node throw new Error("ScrollRegion.scrollToRect: requires a rect. Maybe you meant scrollTo?") - if not rect.top or not rect.height + if not rect.top? or not rect.height? throw new Error("ScrollRegion.scrollToRect: requires a rect with `top` and `height` attributes.") @_scroll {position, settle, done}, => rect