Missed a if block for valid password