...means you can use `blocks.shift()` here and `blocks.pop()` above

can even condense this into a ternary