GetBlock returns the block at the given height, if there is one, otherwise it returns an error.
(ctx context.Context, height uint64)
| 39 | // GetBlock returns the block at the given height, if there is one, |
| 40 | // otherwise it returns an error. |
| 41 | func (c *Chain) GetBlock(ctx context.Context, height uint64) (*legacy.Block, error) { |
| 42 | return c.store.GetBlock(ctx, height) |
| 43 | } |
| 44 | |
| 45 | // GenerateBlock generates a valid, but unsigned, candidate block from |
| 46 | // the current pending transaction pool. It returns the new block and |