Skip to content

Commit

Permalink
neofs-adm: add check for wallet creation
Browse files Browse the repository at this point in the history
The only command that can create alphabet wallets is init.
The only commands that can create contract wallet are init and update-contracts.

Closes #2380.

Signed-off-by: Ekaterina Pavlova <ekt@morphbits.io>
  • Loading branch information
AliceInHunterland committed Aug 17, 2023
1 parent 66bc5b2 commit 5936617
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ minor release, the component will be purged, so be prepared (see `Updating` sect
- Storage node no longer ignores unhealthy shards on startup (#2464)
- Processing of status errors returned by API client from NeoFS SDK RC-9 (#2465)
- `neofs-lens write-cache list` command duplication (#2505)
- `neofs-adm` works with contract wallet in `init` and `update-contracts` commands only(#2134)

### Removed
- Deprecated `morph.rpc_endpoint` SN and `morph.endpoint.client` IR config sections (#2400)
Expand Down
2 changes: 1 addition & 1 deletion cmd/neofs-adm/internal/modules/morph/initialize.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ func newInitializeContext(cmd *cobra.Command, v *viper.Viper) (*initializeContex
}

var w *wallet.Wallet
if cmd.Name() != "deploy" {
if cmd.Name() == "update-contracts" || cmd.Name() == "init" {
w, err = openContractWallet(v, cmd, walletDir)
if err != nil {
return nil, err
Expand Down

0 comments on commit 5936617

Please sign in to comment.