moduleDataSetup = $moduleDataSetup; $this->customerSetupFactory = $customerSetupFactory; } /** * {@inheritdoc} */ public function apply() { $customerSetup = $this->customerSetupFactory->create(['setup' => $this->moduleDataSetup]); $entityTypeId = $customerSetup->getEntityTypeId(Customer::ENTITY); $attributeId = $customerSetup->getAttributeId($entityTypeId, 'gender'); $option = ['attribute_id' => $attributeId, 'values' => [3 => 'Not Specified']]; $customerSetup->addAttributeOption($option); } /** * {@inheritdoc} */ public static function getDependencies() { return [ UpdateCustomerAttributesMetadata::class, ]; } /** * {@inheritdoc} */ public static function getVersion() { return '2.0.2'; } /** * {@inheritdoc} */ public function getAliases() { return []; } }