Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fix bugs

  • Loading branch information...
commit 06bbc1f22199218bfc3d19fe1c4d84426b71b9c8 1 parent 8819222
@aizatto authored
View
2  Entity/FacebookUser.php
@@ -7,6 +7,8 @@
/**
* Aizatto\Bundle\FacebookBundle\Entity\Users
+ *
+ * @ORM\HasLifecycleCallbacks()
*/
abstract class FacebookUser
{
View
2  Entity/User.php
@@ -7,6 +7,8 @@
/**
* Aizatto\Bundle\FacebookBundle\Entity\User;
+ *
+ * @ORM\HasLifecycleCallbacks()
*/
abstract class User extends BaseUser
{
View
11 Security/User/Provider/FacebookProvider.php
@@ -80,13 +80,13 @@ public function createUserFromUid($facebook_id) {
->findOneBy(array('facebook_id' => $facebook_id));
if (!$fbuser) {
- $fbuser = newv($this->facebook_user_class);
+ $fbuser = newv($this->facebook_user_class, array());
}
$fbuser->setAccessToken($this->facebook->getAccessToken());
$this->facebook_manager->updateFacebookUser($fbuser);
- $user = id(new User())
+ $user = id(newv($this->user_class, array()))
->setPassword('')
->setUsername($fbuser->getUsername() ?: '')
->setEmail($fbuser->getEmail())
@@ -96,7 +96,8 @@ public function createUserFromUid($facebook_id) {
->setBirthday($fbuser->getBirthday())
->setAge($fbuser->getAge())
->setEnabled(true)
- ->setFacebookID($fbuser->getFacebookID());
+ ->setFacebookID($fbuser->getFacebookID())
+ ->setCreatedAtValue();
$user->addRole('ROLE_FACEBOOK');
$user->addRole('ROLE_USER');
@@ -109,7 +110,9 @@ public function createUserFromUid($facebook_id) {
if (true || $this->debug) {
}
- var_dump(__FILE__);
+ var_dump($e->getMessage());
+ var_dump($e->getCode());
+ var_dump($e->getType());
exit();
throw $e;
}
Please sign in to comment.
Something went wrong with that request. Please try again.