for some reason param check function didn't work