Are SN2 reactions in equilibrium?
When we talk about Sn1 or Sn2 reactions (and any other reaction to be honest), not only the reactants are crucial to describe what's going on but also the solvent you used. It is perfectly possible that the second reaction will be favored in the direction shown, as long as you use the right solvent for this.

There are two types of solvents one can use in an Sn2 reaction: polar protic (which has a reasonably acidic hydrogen in its structure) and polar aprotic (has a net dipole moment but no acidic hydrogens).

Examples of polar protic solvents: Water, methanol, ethanol, ammonia etc



Examples of polar aprotic solvents: DMSO, acetonitrile, acetone etc



So what does the solvent has to do with the reaction?


Nucleophiles are negatively charged species or dipoles, they will attack a sufficiently positive center (usually a carbon atom connected to an electron withdrawing group)
The solvent is commonly present in significant excess compared to the
reactants.


When you use a polar protic solvent, such as methanol or water, the nucleophile species (ions such as Cl- or molecules such as ethanol) will be surrounded by an overwhelming number of solvent molecules that will interact strongly with them by dipole-dipole interactions or hydrogen bonding. This creates a barrier around the nucleophile, making it considerably more difficult to approach the positive center and consequently slows the reaction.



Smaller nucleophiles (such as F-) will be surrounded by a bigger number of solvent molecules than bigger nucleophiles (such as I-), so this surrounding effect is stronger in smaller species.

If you consider only the nucleophile, Br- is stronger than I- since it has a smaller ionic radius and, therefore, has a more 'concentrated' electron cloud (less polarizable). If no solvent effect was considered, the reaction as shown in your textbook would be incorrect since the equilibrium would be towards the formation of methyl bromide.



HOWEVER, if you use a polar protic solvent, like methanol, the order of nucleophilicity is inverted (because of that surrounding barrier of solvent molecules) and I- becomes a better nucleophile than Br-.



So, to be consistent and correct, your textbook should also provide the solvent in which this reaction is done. If it is a polar protic one then it is correct.

(I took these pictures from master organic chemistry, they have a good text talking about it here: https://www.masterorganicchemistry.com/2012/12/04/deciding-sn1sn2e1e2-the-solvent/ )