In this example, these "lower-than-optimal" prices weren't passed on to the end consumers in the first place–instead, arbitrageurs like the author's friend would take advantage of them to gain a profit. The end prices that the average, uninformed buyer would see would therefore be inflated, with traders like the author's friend taking their cut.
Sure, the rise of more efficient, algorithmic players decreased the profitability of less sophisticated middlemen like the author's friend. But, since these algorithmic players were more efficient, they were able to take less of a cut, leading to lower prices (and overall benefit) for the average buyer.