Changes to this setting (and any other setting in the Entra portal) are logged within the Entra Audit log, and also flow to the Unified audit log if using Microsoft 365. In particular, you can find it under the Core Directory service and DirectoryManagement category as shown below:
The user who made the change is listed as the Actor. To access the log, follow the instructions here: https://learn.microsoft.com/en-us/entra/identity/monitoring-health/concept-audit-logs