File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed
app/src/main/java/ch/lock/mobile/android/deviceinfo/utils Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -55,9 +55,12 @@ class DeviceUtils(
55
55
*/
56
56
val imei: String
57
57
get() = try {
58
- telephonyManager.deviceId ? : " "
58
+ when (Build .VERSION .SDK_INT ) {
59
+ in 1 .. 28 -> telephonyManager.deviceId ? : " "
60
+ else -> " 안드로이드 보안 정책에 의해 확인 불가"
61
+ }
59
62
} catch (e: Exception ) {
60
- " 안드로이드 10부터는 imei를 확인할 수 없습니다. "
63
+ " "
61
64
}
62
65
63
66
/* *
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ class SimUtils(
37
37
in 1 .. 21 -> telephonyManager.simSerialNumber ? : " "
38
38
in 22 .. 28 -> subscriptionManager.activeSubscriptionInfoList?.firstOrNull()?.iccId
39
39
? : " 유심이 장착되어 있지 않아 확인 불가"
40
- else -> " 안드로이드 정책에 의해 확인 불가"
40
+ else -> " 안드로이드 보안 정책에 의해 확인 불가"
41
41
}
42
42
} catch (e: Exception ) {
43
43
" "
You can’t perform that action at this time.
0 commit comments