Check if valid while creating product and variant in migration.