please add empty line after section where you check validity of input parameters