Don't try to fill space if we don't have a message wrapper

This commit is contained in:
David Baker 2015-08-11 17:20:31 +01:00
parent 18c56a171e
commit be5aaeaad7

View File

@ -201,8 +201,8 @@ module.exports = {
}, },
fillSpace: function() { fillSpace: function() {
if (!this.refs.messageWrapper) return;
var messageWrapper = this.refs.messageWrapper.getDOMNode(); var messageWrapper = this.refs.messageWrapper.getDOMNode();
if (!messageWrapper) return;
if (messageWrapper.scrollTop < messageWrapper.clientHeight && this.state.room.oldState.paginationToken) { if (messageWrapper.scrollTop < messageWrapper.clientHeight && this.state.room.oldState.paginationToken) {
this.setState({paginating: true}); this.setState({paginating: true});