Perform deep comparison for card data when receiving new props (#9270)

Fixes #9226
master
ThibG 6 years ago committed by Eugen Rochko
parent c81bdafb07
commit bbd8fdd185
  1. 2
      app/javascript/mastodon/features/status/components/card.js

@ -73,7 +73,7 @@ export default class Card extends React.PureComponent {
};
componentWillReceiveProps (nextProps) {
if (this.props.card !== nextProps.card) {
if (!this.props.card.equals(nextProps.card)) {
this.setState({ embedded: false });
}
}

Loading…
Cancel
Save