fixed typo, checking wrong argument