fix: delete pdf worker after switching assets (#767)
This commit is contained in:
Родитель
f2990971bf
Коммит
e19d3729f7
|
@ -191,6 +191,9 @@ export default class Canvas extends React.Component<ICanvasProps, ICanvasState>
|
|||
this.selectedRegionIds = [];
|
||||
this.imageMap.removeAllFeatures();
|
||||
this.imageMap.resetAllLayerVisibility();
|
||||
if (this.state.pdfFile) {
|
||||
await this.state.pdfFile.destroy();
|
||||
}
|
||||
|
||||
this.setState({
|
||||
currentAsset: this.props.selectedAsset,
|
||||
|
|
Загрузка…
Ссылка в новой задаче