/** * Returns user profile data * * @param $id * @return array|null */ public function getUserProfileData($id) { $userModel = $this->userStorage->getUserData($id); if ($userModel === null) { return null; } return ['email' => $userModel->email, 'created_at' => $userModel->created_at->toDateTimeString()]; }
/** * @inheritdoc */ public function retrieveByCredentials(array $credentials) { return $this->userStorage->getByCredentials($credentials); }