fixed ensure type