Fix key check.