mirror of
https://github.com/gedoor/legado.git
synced 2024-07-06 23:47:49 +08:00
优化
This commit is contained in:
parent
a4fc1b10f5
commit
19840997bd
@ -5,9 +5,8 @@ import org.mozilla.javascript.Context
|
||||
object Rhino {
|
||||
|
||||
inline fun <R> use(block: Context.() -> R): R {
|
||||
val context = Context.enter()
|
||||
return try {
|
||||
block.invoke(context)
|
||||
block.invoke(Context.enter())
|
||||
} finally {
|
||||
Context.exit()
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user