belongsTo relation in laravel is returning null
public function games(){
return $this->belongsTo('App\Models\Game');
}
but when i provide key as argument it seems to work fine
public function games(){
return $this->belongsTo('App\Models\Game','game_id');
}
but as per the docs game_id
is itself is a default argument. What is the small thing i am missing here.
Thanks