forked from TrueCloudLab/frostfs-contract
[#174] subnet: Sync notifications and method names
Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
parent
76933df0a9
commit
c2b7e638fa
2 changed files with 7 additions and 7 deletions
|
@ -3,7 +3,7 @@ safemethods: ["version"]
|
|||
permissions:
|
||||
- methods: ["update"]
|
||||
events:
|
||||
- name: SubnetPut
|
||||
- name: Put
|
||||
parameters:
|
||||
- name: id
|
||||
type: ByteArray
|
||||
|
@ -11,11 +11,11 @@ events:
|
|||
type: PublicKey
|
||||
- name: info
|
||||
type: ByteArray
|
||||
- name: SubnetDelete
|
||||
- name: Delete
|
||||
parameters:
|
||||
- name: id
|
||||
type: ByteArray
|
||||
- name: NodeRemove
|
||||
- name: RemoveNode
|
||||
parameters:
|
||||
- name: subnetID
|
||||
type: ByteArray
|
||||
|
|
|
@ -106,7 +106,7 @@ func Put(id []byte, ownerKey interop.PublicKey, info []byte) {
|
|||
if !runtime.CheckWitness(ownerKey) {
|
||||
panic("put: witness check failed")
|
||||
}
|
||||
runtime.Notify("SubnetPut", id, ownerKey, info)
|
||||
runtime.Notify("Put", id, ownerKey, info)
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -174,7 +174,7 @@ func Delete(id []byte) {
|
|||
key[0] = infoPrefix
|
||||
storage.Delete(ctx, key)
|
||||
|
||||
runtime.Notify("SubnetDelete", id)
|
||||
runtime.Notify("Delete", id)
|
||||
}
|
||||
|
||||
// AddNodeAdmin adds new node administrator to the specified subnetwork.
|
||||
|
@ -323,7 +323,7 @@ func RemoveNode(subnetID []byte, node interop.PublicKey) {
|
|||
|
||||
storage.Delete(ctx, append(stKey, node...))
|
||||
|
||||
runtime.Notify("NodeRemove", subnetID, node)
|
||||
runtime.Notify("RemoveNode", subnetID, node)
|
||||
}
|
||||
|
||||
// NodeAllowed checks if node is included in the
|
||||
|
|
Loading…
Reference in a new issue