Answer
$(a-b)\left( a-b+2 \right)$
Work Step by Step
Factoring the $GCF=
(a-b)
,$ the given expression, $
(a-b)^2+2(a-b)
,$ is equivalent to
\begin{array}{l}\require{cancel}
(a-b)\left( \dfrac{(a-b)^2}{(a-b)}+\dfrac{2(a-b)}{(a-b)} \right)
\\\\=
(a-b)\left( (a-b)+2 \right)
\\\\=
(a-b)\left( a-b+2 \right)
.\end{array}