[#1381] neofs-cli: Move JSON and verbose printing to a common package
Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
parent
c57114def3
commit
71d823f192
7 changed files with 57 additions and 39 deletions
|
@ -189,7 +189,7 @@ var netInfoCmd = &cobra.Command{
|
|||
|
||||
func prettyPrintNodeInfo(cmd *cobra.Command, i *netmap.NodeInfo, jsonEncoding bool) {
|
||||
if jsonEncoding {
|
||||
printJSONMarshaler(cmd, i, "node info")
|
||||
common.PrettyPrintJSON(cmd, i, "node info")
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -206,7 +206,7 @@ func prettyPrintNodeInfo(cmd *cobra.Command, i *netmap.NodeInfo, jsonEncoding bo
|
|||
|
||||
func prettyPrintNetmap(cmd *cobra.Command, nm *control.Netmap, jsonEncoding bool) {
|
||||
if jsonEncoding {
|
||||
printJSONMarshaler(cmd, nm, "netmap")
|
||||
common.PrettyPrintJSON(cmd, nm, "netmap")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue