浏览代码

[11/n] lpac-jni: Fix validity check for LPA

none of the properties should be "by lazy" because we depend on whether
they error to detect if the LPA is still valid.
Peter Cai 2 年之前
父节点
当前提交
d95341b764
共有 1 个文件被更改,包括 3 次插入4 次删除
  1. 3 4
      libs/lpac-jni/src/main/java/net/typeblog/lpac_jni/impl/LocalProfileAssistantImpl.kt

+ 3 - 4
libs/lpac-jni/src/main/java/net/typeblog/lpac_jni/impl/LocalProfileAssistantImpl.kt

@@ -20,11 +20,10 @@ class LocalProfileAssistantImpl(
     }
 
     override val profiles: List<LocalProfileInfo>
-        get() = LpacJni.es10cGetProfilesInfo(contextHandle)!!.asList() // TODO: Maybe we need better error handling
+        get() = LpacJni.es10cGetProfilesInfo(contextHandle)!!.asList()
 
-    override val eID: String by lazy {
-        LpacJni.es10cGetEid(contextHandle)!!
-    }
+    override val eID: String
+        get() = LpacJni.es10cGetEid(contextHandle)!!
 
     override val euiccInfo2: EuiccInfo2?
         get() = LpacJni.es10cexGetEuiccInfo2(contextHandle)