I would like to have the entire last line in a box, but when I compile, it only boxes the first equation and doesn't even print the second equation. Does anyone know how to fix this?
Here's my MWE.
\documentclass[12pt]{article}
\usepackage{amsmath}
\usepackage{mathtools}
\begin{document}
\begin{alignat*}{3}
\left| x \right. & \left. - 2 \right| & &=1 &\\
x - 2 &= 1& &\text{ or } & x - 2 &= -1\\
\Aboxed{x &= 3& &\text{ or }& x &= 1}
\end{alignat*}
\end{document}
I was going to include an image of what it produces, but it won't let me since I'm a new user. :)

