fix: repair the date of birth import in Teamer::fromUserinfo
This commit is contained in:
1 parent
642102263e
commit
8b09845d96
1 file changed
+3
-3
@@ -250,11 +250,11 @@ class Teamer implements TimestampableEntityInterface, SoftDeletableEntityInterfa
|
||||
->setGender($userinfo['profile']['gender'] ?? null)
|
||||
;
|
||||
|
||||
if (null !== $userinfo['profile']['date_of_birth'] ?? null) {
|
||||
if (true === isset($userinfo['profile']['date_of_birth'])) {
|
||||
try {
|
||||
$dateOfBirth = new \DateTimeImmutable(['profile']['date_of_birth']);
|
||||
$dateOfBirth = new \DateTimeImmutable((string) $userinfo['profile']['date_of_birth']);
|
||||
$instance->setDateOfBirth($dateOfBirth);
|
||||
} catch (\Exception $e) {
|
||||
} catch (\Exception|\TypeError $e) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user