#471 Add type checks