formatting
This commit is contained in:
@@ -40,7 +40,7 @@ import kotlinx.coroutines.launch
|
||||
|
||||
@Composable
|
||||
fun ZapNoteCompose(baseReqResponse: ZapReqResponse, accountViewModel: AccountViewModel, nav: (String) -> Unit) {
|
||||
val baseNoteRequest by baseReqResponse.request.live().metadata.observeAsState()
|
||||
val baseNoteRequest by baseReqResponse.zapRequest.live().metadata.observeAsState()
|
||||
|
||||
var baseAuthor by remember {
|
||||
mutableStateOf<User?>(null)
|
||||
|
||||
@@ -7,7 +7,7 @@ import com.vitorpamplona.amethyst.model.Note
|
||||
import kotlinx.collections.immutable.ImmutableList
|
||||
|
||||
@Immutable
|
||||
data class ZapReqResponse(val request: Note, val zapEvent: Note)
|
||||
data class ZapReqResponse(val zapRequest: Note, val zapEvent: Note)
|
||||
|
||||
@Stable
|
||||
sealed class LnZapFeedState {
|
||||
|
||||
@@ -35,10 +35,10 @@ class UserZapsTest {
|
||||
val actual = UserZaps.forProfileFeed(zaps)
|
||||
|
||||
Assert.assertEquals(1, actual.count())
|
||||
Assert.assertEquals(zapRequest, actual.first().first)
|
||||
Assert.assertEquals(zapRequest, actual.first().zapRequest)
|
||||
Assert.assertEquals(
|
||||
BigDecimal(200),
|
||||
(actual.first().second.event as LnZapEventInterface).amount()
|
||||
(actual.first().zapEvent.event as LnZapEventInterface).amount()
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user