Commit aa0f2a1c authored by Filipe de Lima Brito's avatar Filipe de Lima Brito

Update UserAvatarHelper.kt

parent 06be1d3c
......@@ -70,9 +70,9 @@ object UserAvatarHelper {
val splitUsername = username.split(".")
val splitCount = splitUsername.size
if (splitCount > 1 && splitUsername[0].isNotEmpty() && splitUsername[1].isNotEmpty()) {
if (splitCount > 1 && splitUsername[0].isNotEmpty() && splitUsername[splitCount-1].isNotEmpty()) {
val firstInitial = splitUsername[0].substring(0, 1)
val secondInitial = splitUsername[1].substring(0, 1)
val secondInitial = splitUsername[splitCount-1].substring(0, 1)
return (firstInitial + secondInitial).toUpperCase()
} else {
if (username.length > 1) {
......
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