Sentry 2 Facebook Oauth On Laravel says that calling the undefined :: profile () method

I am using Laravel 4.1 and using facebook/php-sdk with a sentinel, this actually follows from these questions: Facebook Login with Sentry, for user [email], password is not required .

This code no longer works:

  $profile = $user->profiles()->save($profile); 

causes this error: enter image description here

How to solve it?

the route for this is available here Route code

My models are bellows:

Profile Model:

 <?php class Profile extends \Eloquent { public function user() { return $this->belongsTo('User'); } } 

The user model contains:

 public function profiles() { return $this->hasMany('Profile'); } 
0
source share
1 answer

Solved in the comments:

Do you customize the watch model using this method http://forums.laravel.io/viewtopic.php?pid=48274#p48274 ? - user1279647

0
source

Source: https://habr.com/ru/post/1501881/


All Articles