Next 2 blocks shouldn't end up in master like @NimbusBP1729  has mentionned.
You can use a simple for loop.
This is managed quite gracefully in the updated shopping pull