incorrect if statement on $jname