mirror of
https://github.com/greenart7c3/Amber.git
synced 2026-10-05 19:08:23 +00:00
clear permissions when GET_PUBLIC_KEY
This commit is contained in:
@@ -87,6 +87,9 @@ fun sendResult(
|
||||
) {
|
||||
val activity = context.getAppCompatActivity()
|
||||
if (packageName != null) {
|
||||
if (intentData.type == SignerType.GET_PUBLIC_KEY) {
|
||||
account.savedApps.clear()
|
||||
}
|
||||
permissions?.filter { it.checked }?.forEach {
|
||||
val type = it.type.toUpperCase(Locale.current)
|
||||
val permissionKey = if (it.type == "sign_event") "$packageName-$type-${it.kind}" else "$packageName-$type"
|
||||
|
||||
@@ -3,13 +3,11 @@ package com.greenart7c3.nostrsigner.ui.components
|
||||
import androidx.compose.foundation.layout.Box
|
||||
import androidx.compose.foundation.layout.fillMaxWidth
|
||||
import androidx.compose.foundation.layout.padding
|
||||
import androidx.compose.material3.ButtonDefaults
|
||||
import androidx.compose.material3.Text
|
||||
import androidx.compose.material3.TextButton
|
||||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.ui.Alignment
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.graphics.Color
|
||||
import androidx.compose.ui.unit.dp
|
||||
import com.greenart7c3.nostrsigner.ui.theme.ButtonBorder
|
||||
|
||||
@@ -26,10 +24,7 @@ fun RawJsonButton(
|
||||
) {
|
||||
TextButton(
|
||||
shape = ButtonBorder,
|
||||
onClick = onCLick,
|
||||
colors = ButtonDefaults.textButtonColors(
|
||||
contentColor = Color.Black
|
||||
)
|
||||
onClick = onCLick
|
||||
) {
|
||||
Text(text)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user