working commit
This commit is contained in:
+2
-6
@@ -54,7 +54,6 @@ func (cli *Client) CreateGrantByAccountID(ctx context.Context, hosturi, accountI
|
||||
return res, err
|
||||
}
|
||||
|
||||
|
||||
func (cli *Client) CreateGrantByUsername(ctx context.Context, hosturi, username, right, pattern string) (string, error) {
|
||||
var err error
|
||||
var res string
|
||||
@@ -65,8 +64,8 @@ func (cli *Client) CreateGrantByUsername(ctx context.Context, hosturi, username,
|
||||
}
|
||||
operParams := operator.CreateGrantParams{
|
||||
Username: username,
|
||||
Right: right,
|
||||
Pattern: pattern,
|
||||
Right: right,
|
||||
Pattern: pattern,
|
||||
}
|
||||
paramsJson, err := json.Marshal(operParams)
|
||||
if err != nil {
|
||||
@@ -90,7 +89,6 @@ func (cli *Client) CreateGrantByUsername(ctx context.Context, hosturi, username,
|
||||
return res, err
|
||||
}
|
||||
|
||||
|
||||
func (cli *Client) GetGrant(ctx context.Context, hosturi, id string) (*descr.Grant, error) {
|
||||
var err error
|
||||
res := &descr.Grant{}
|
||||
@@ -124,8 +122,6 @@ func (cli *Client) GetGrant(ctx context.Context, hosturi, id string) (*descr.Gra
|
||||
return res, err
|
||||
}
|
||||
|
||||
|
||||
|
||||
func (cli *Client) UpdateGrant(ctx context.Context, hosturi, grantID, newPattern string) error {
|
||||
var err error
|
||||
|
||||
|
||||
Reference in New Issue
Block a user