Fix some issues with the block tree