Commit df0c7c61 authored by mengcuiguang's avatar mengcuiguang

代码优化

parent d7507051
...@@ -209,18 +209,10 @@ class DeviceInfo private constructor() { ...@@ -209,18 +209,10 @@ class DeviceInfo private constructor() {
imei = imei =
(MintsApplication.getContext() (MintsApplication.getContext()
.getSystemService(Context.TELEPHONY_SERVICE) as TelephonyManager).deviceId .getSystemService(Context.TELEPHONY_SERVICE) as TelephonyManager).deviceId
} catch (e: Exception) {
try {
imei = Settings.Secure.getString(
MintsApplication.getContext().contentResolver,
Settings.Secure.ANDROID_ID
)
} catch (e: Exception) { } catch (e: Exception) {
imei = "" imei = ""
e.printStackTrace() e.printStackTrace()
} }
e.printStackTrace()
}
return imei return imei
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment