web/removebg: fix the incorrect file condition

This commit is contained in:
wukko 2025-01-17 01:51:10 +06:00
parent b85771dc1d
commit 8a5b25b4ce
No known key found for this signature in database
GPG key ID: 3E30B3F26C7B4AA2

View file

@ -63,7 +63,7 @@ const removeImageBackground = async (file: File) => {
}
self.onmessage = async (event: MessageEvent) => {
if (event.data.cobaltRemoveBgWorker.file) {
if (event.data.cobaltRemoveBgWorker) {
await removeImageBackground(event.data.cobaltRemoveBgWorker.file);
self.close();
}