// getBlockAPI returns a block api for listing blocks. func getBlockAPI(c *modelcmd.ModelCommandBase) (block.BlockListAPI, error) { root, err := c.NewAPIRoot() if err != nil { return nil, err } return apiblock.NewClient(root), nil }
// getBlockAPI returns a block api for listing blocks. func getBlockAPI(c *modelcmd.ModelCommandBase) (listBlocksAPI, error) { root, err := c.NewAPIRoot() if err != nil { return nil, errors.Trace(err) } return block.NewClient(root), nil }