A simple question about the uuid
This question is originally posted in the "Troubleshooting" forum, but it is actually not a trouble, but a simple question. So I post it again here, hope it is fine :P
So this question is for the developers of WordPress Android.
It is a simple question about the "uuid" used in the uploadStats() method in "wpAndroid.java".
By reading the code for the Android version of WordPress, I noticed that in the Android version, this "uuid" is just a unique ID that randomly generated and stored as the first record in WordPress’s own SQLite database on the Android device.
However, in the code of the iPhone version of WordPress, the uuid used in the same method is actually the device's uuid.
So my question is, when writing the code for WordPress Android, why the "uuid" does not use the device uuid? (I mean it can just be easily obtained by calling TelephonyManager.getDeviceId(), right?)
Is this because calling TelephonyManager.getDeviceId() will trigger the "android.permission.READ_PHONE_STATE" permission checking?
I mean, is it because WordPress for Android is actually trying to avoid such additional permission request when writing the code? Is it the reason why it is using a random-generated uuid instead of the real device id (such as on iPhone's version of WordPress)?
Appreciate if the original developer of that wpAndroid class could answer my question or just confirm my guessing :)
Yes, a random id is better than the device id because it doesn't require that permission which reads quite poorly as 'read phone state and identity'.
Thanks a lot for the quick reply~~~ :)
This topic has been closed to new replies.