[#625] morph/client: make method names constant
We don't use custom names and the only place where custom method option is used it provides the default name and can be omitted. Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
parent
35dec2f494
commit
3c5b62d839
44 changed files with 249 additions and 1097 deletions
|
@ -59,17 +59,17 @@ func (x Client) ManageAdmins(prm ManageAdminsPrm) (*ManageAdminsPrm, error) {
|
|||
args = append(args, prm.group, prm.admin)
|
||||
|
||||
if prm.rm {
|
||||
method = "removeClientAdmin"
|
||||
method = removeClientAdminMethod
|
||||
} else {
|
||||
method = "addClientAdmin"
|
||||
method = addClientAdminMethod
|
||||
}
|
||||
} else {
|
||||
args = append(args, prm.admin)
|
||||
|
||||
if prm.rm {
|
||||
method = "removeNodeAdmin"
|
||||
method = removeNodeAdminMethod
|
||||
} else {
|
||||
method = "addNodeAdmin"
|
||||
method = addNodeAdminMethod
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue