Skip to content

Instantly share code, notes, and snippets.

@EricMcWinNer
Last active September 10, 2020 15:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save EricMcWinNer/76b6006b8dcc173e6b13d759a5a681cd to your computer and use it in GitHub Desktop.
Save EricMcWinNer/76b6006b8dcc173e6b13d759a5a681cd to your computer and use it in GitHub Desktop.
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class User extends Model
{
/**
* Get's this user's vote
*/
public function vote()
{
return $this->hasOne(App\Models\Vote::class);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment