Confusion with Formula for LM317 circuit

Your guess would have been right if the LM317 referenced the 1.25V to the ground terminal - but it doesn't
it references it to the output terminal (the technical reason for this is to provide a known closed-loop gain
throughout its range of operation). You apply the voltage divider rule upside-down, that's all.