BookStack/app/Auth/SocialAccount.php

31 lines
558 B
PHP
Raw Normal View History

2021-06-26 15:23:15 +00:00
<?php
namespace BookStack\Auth;
use BookStack\Interfaces\Loggable;
use BookStack\Model;
2015-09-04 19:40:36 +00:00
/**
2021-06-26 15:23:15 +00:00
* Class SocialAccount.
*
* @property string $driver
2021-06-26 15:23:15 +00:00
* @property User $user
*/
class SocialAccount extends Model implements Loggable
2015-09-04 19:40:36 +00:00
{
protected $fillable = ['user_id', 'driver', 'driver_id', 'timestamps'];
public function user()
{
return $this->belongsTo(User::class);
2015-09-04 19:40:36 +00:00
}
/**
* @inheritDoc
*/
public function logDescriptor(): string
{
return "{$this->driver}; {$this->user->logDescriptor()}";
}
2015-09-04 19:40:36 +00:00
}