mirror of
https://github.com/nostr-protocol/nips.git
synced 2025-08-11 05:30:47 -04:00
[NIP-55] - Add the rejected permission check in the code samples (#1755)
This commit is contained in:
16
55.md
16
55.md
@@ -339,6 +339,8 @@ If the user chose to always reject the event, signer application will return the
|
||||
```kotlin
|
||||
if (result == null) return
|
||||
|
||||
if (it.getColumnIndex("rejected") > -1) return
|
||||
|
||||
if (result.moveToFirst()) {
|
||||
val index = it.getColumnIndex("result")
|
||||
if (index < 0) return
|
||||
@@ -364,6 +366,8 @@ If the user chose to always reject the event, signer application will return the
|
||||
```kotlin
|
||||
if (result == null) return
|
||||
|
||||
if (it.getColumnIndex("rejected") > -1) return
|
||||
|
||||
if (result.moveToFirst()) {
|
||||
val index = it.getColumnIndex("result")
|
||||
val indexJson = it.getColumnIndex("event")
|
||||
@@ -390,6 +394,8 @@ If the user chose to always reject the event, signer application will return the
|
||||
```kotlin
|
||||
if (result == null) return
|
||||
|
||||
if (it.getColumnIndex("rejected") > -1) return
|
||||
|
||||
if (result.moveToFirst()) {
|
||||
val index = it.getColumnIndex("result")
|
||||
val encryptedText = it.getString(index)
|
||||
@@ -414,6 +420,8 @@ If the user chose to always reject the event, signer application will return the
|
||||
```kotlin
|
||||
if (result == null) return
|
||||
|
||||
if (it.getColumnIndex("rejected") > -1) return
|
||||
|
||||
if (result.moveToFirst()) {
|
||||
val index = it.getColumnIndex("result")
|
||||
val encryptedText = it.getString(index)
|
||||
@@ -438,6 +446,8 @@ If the user chose to always reject the event, signer application will return the
|
||||
```kotlin
|
||||
if (result == null) return
|
||||
|
||||
if (it.getColumnIndex("rejected") > -1) return
|
||||
|
||||
if (result.moveToFirst()) {
|
||||
val index = it.getColumnIndex("result")
|
||||
val encryptedText = it.getString(index)
|
||||
@@ -462,6 +472,8 @@ If the user chose to always reject the event, signer application will return the
|
||||
```kotlin
|
||||
if (result == null) return
|
||||
|
||||
if (it.getColumnIndex("rejected") > -1) return
|
||||
|
||||
if (result.moveToFirst()) {
|
||||
val index = it.getColumnIndex("result")
|
||||
val encryptedText = it.getString(index)
|
||||
@@ -486,6 +498,8 @@ If the user chose to always reject the event, signer application will return the
|
||||
```kotlin
|
||||
if (result == null) return
|
||||
|
||||
if (it.getColumnIndex("rejected") > -1) return
|
||||
|
||||
if (result.moveToFirst()) {
|
||||
val index = it.getColumnIndex("result")
|
||||
val relayJsonText = it.getString(index)
|
||||
@@ -510,6 +524,8 @@ If the user chose to always reject the event, signer application will return the
|
||||
```kotlin
|
||||
if (result == null) return
|
||||
|
||||
if (it.getColumnIndex("rejected") > -1) return
|
||||
|
||||
if (result.moveToFirst()) {
|
||||
val index = it.getColumnIndex("result")
|
||||
val eventJson = it.getString(index)
|
||||
|
Reference in New Issue
Block a user