调整初始化方式

master
yutent 2023-09-04 19:21:05 +08:00
parent 2aaa711a89
commit 8abfbee5dc
1 changed files with 4 additions and 5 deletions

View File

@ -189,6 +189,10 @@ class EventEmitter {
window.native = new EventEmitter()
Object.assign(native, {
async init() {
let env = await handler('init') //.then(r => (native.env = r))
native.env = env
},
quit() {
return handler('quit', {}, null)
},
@ -401,8 +405,3 @@ Object.assign(native, {
handler
})
!(async function () {
let env = await handler('init') //.then(r => (native.env = r))
native.env = env
})()