18 lines
473 B
Kotlin
18 lines
473 B
Kotlin
package com.aiosman.riderpro.data
|
|
|
|
import com.aiosman.riderpro.test.TestDatabase
|
|
|
|
interface UserService {
|
|
suspend fun getUserProfile(id:String): AccountProfile
|
|
}
|
|
|
|
class TestUserServiceImpl : UserService {
|
|
override suspend fun getUserProfile(id: String): AccountProfile {
|
|
TestDatabase.accountData.forEach {
|
|
if (it.id == id.toInt()) {
|
|
return it
|
|
}
|
|
}
|
|
return AccountProfile(0, 0, 0, "", "", "", "")
|
|
}
|
|
} |