Prove the sqrt(8) is not a rational number

This is the proof I used. Does anyone know if it is correct?

Assume that the sqrt(8) is a rational number.

sqrt(8) = n/m Assume no common factors between n and m

8 = n^2/m^2

8m^2 = n^2

So n^2 must be an even number since anything muliplied by 8 is even.

n must be even as well because even numbers squared are even, odd numbers squared are odd.

Represent n as 4k

n^2 = (4k)^2 --> 4^2k^2 --> 16k^2

8m^2 = 16k^2

m^2 = 2k^2

So, m^2 is even

So, m is even

Therefore m and n have a common factor, it disproves my assumption