I made a condition that if the device doesn't have Device name it will get the Device model. But the thing is on some devices I'm getting the Device model even the device have Device name. Do you guys have an idea why I'm getting Device model not device name?
fun getDeviceName(): String =
Settings.Global.getString(context.contentResolver, "device_name") ?: getDeviceNameIfNull()