fix: stop media stream on hide
When the image capture dialog is hidden, stop the media stream. Didn't work becasue function was executed during setup.
This commit is contained in:
parent
4888e85df1
commit
41f38f5bc6
1 changed files with 3 additions and 1 deletions
|
|
@ -98,7 +98,9 @@ frappe.ui.Capture = class {
|
|||
fieldname: "total_count",
|
||||
},
|
||||
],
|
||||
on_hide: this.stop_media_stream(),
|
||||
on_hide: () => {
|
||||
this.stop_media_stream();
|
||||
},
|
||||
});
|
||||
|
||||
me.$template = $(frappe.ui.Capture.TEMPLATE);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue