To modify the behavior of the connector bundle the following events are registered:
You can implement the [LDAPApiProviderInterface](https://gitlab.tugraz.at/dbp/relay/dbp-relay-base-person-connector-ldap-bundle/-/blob/main/src/API/LDAPApiProviderInterface.php)
### PersonUserItemPreEvent
to customize how attributes are fetched from the LDAP server and assigned to the `Person` entity or what `Person` entities
are fetched from certain external services like in the [ALMA Bundle](https://gitlab.tugraz.at/dbp/library/api-alma-bundle).
You'll find an example at [DummyLDAPApiProvider.php](https://gitlab.tugraz.at/dbp/relay/dbp-relay-base-person-connector-ldap-bundle/-/blob/main/src/Service/DummyLDAPApiProvider.php).
This event allows to modify the identifier before a user is loaded from LDAP.
If you don't need any customization, you don't need to implement the interface,
An event subscriber receives a `\Dbp\Relay\BasePersonConnectorLdapBundle\Event\PersonUserItemPreEvent` instance
there is the default implementation which is used by default.
in a service for example in `src/EventSubscriber/PersonUserItemSubscriber.php`: