diff --git a/applications/system/js_app/modules/js_storage.c b/applications/system/js_app/modules/js_storage.c index 717bab8824..05f8ffd40a 100644 --- a/applications/system/js_app/modules/js_storage.c +++ b/applications/system/js_app/modules/js_storage.c @@ -202,6 +202,11 @@ static void js_storage_virtual_mount(struct mjs* mjs) { return; } + if(storage->virtual) { + storage_file_free(storage->virtual); + storage->virtual = NULL; + } + mjs_return(mjs, MJS_UNDEFINED); }