I agree with the answer provided by Mauro ALLEGRANZA.
The following proof shows a different way to eliminate the disjunction, "P v Q", by using disjunctive syllogism (DS). See forall x: Calgary Remix, pp 124-5, for more information.
If you have that rule, it is similar to considering the two cases of the disjunction, case "P" and case "Q", and deriving "P" in both cases. However, because we need to assume "¬Q" to derive the desired implication, which you have done on your line 2, we can take a short-cut. That assumption means we don't have to check the "Q" case in the disjunction. It is contradictory. So we can derive "P" immediately which is what we want. Then we can discharge the assumption by introducing a conditional.
The other direction shows a way to proceed without using an indirect proof. It does use the law of the excluded middle (LEM).
P. D. Magnus, Tim Button with additions by J. Robert Loftis remixed and revised by Aaron Thomas-Bolduc, Richard Zach, forallx Calgary Remix: An Introduction to Formal Logic, Winter 2018. http://forallx.openlogicproject.org/