remove pointless conditional test and associated superfluous variable