Skip to content

Commit

Permalink
oups
Browse files Browse the repository at this point in the history
  • Loading branch information
lgtaxn committed Oct 31, 2019
1 parent 73bc827 commit 692a312
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/AuthorableTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public function createdBy()
{
$relation = $this->belongsTo($this->getUsersModel(), $this->determineCreatedByColumnName());

if (method_exists($this, 'getDeletedAtColumn')) {
if (method_exists($relation->getRelated(), 'getDeletedAtColumn')) {
return $relation->withTrashed();
}

Expand All @@ -55,7 +55,7 @@ public function updatedBy()
{
$relation = $this->belongsTo($this->getUsersModel(), $this->determineUpdatedByColumnName());

if (method_exists($this, 'getDeletedAtColumn')) {
if (method_exists($relation->getRelated(), 'getDeletedAtColumn')) {
return $relation->withTrashed();
}

Expand Down

0 comments on commit 692a312

Please sign in to comment.