Replace unsafe lifecycle methods in bundle.jsx

This commit is contained in:
diondiondion 2025-11-20 16:21:18 +01:00
parent 3cabdd7dcf
commit 2edbfb0dd8

View File

@ -33,13 +33,13 @@ class Bundle extends PureComponent {
forceRender: false, forceRender: false,
}; };
UNSAFE_componentWillMount() { componentDidMount() {
this.load(this.props); this.load(this.props);
} }
UNSAFE_componentWillReceiveProps(nextProps) { componentDidUpdate(prevProps) {
if (nextProps.fetchComponent !== this.props.fetchComponent) { if (prevProps.fetchComponent !== this.props.fetchComponent) {
this.load(nextProps); this.load(this.props);
} }
} }