Skip to content

Commit

Permalink
Switch method bodies [MA-90]
Browse files Browse the repository at this point in the history
  • Loading branch information
zachgarwood committed Jul 17, 2023
1 parent 1a19aec commit f72e781
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/Libraries/Api/Models/BaseApiModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -171,12 +171,12 @@ public function scopeAccessible(Builder $query): Builder

public function scopeOnlyTrashed(Builder $query): Builder
{
return $query->where("{$this->getTable()}.published", false);
return $query->onlyTrashed();
}

public function scopeDraft(Builder $query): Builder
{
return $query->onlyTrashed();
return $query->where("{$this->getTable()}.published", false);
}

public function getTranslatedAttributes(): array
Expand Down

0 comments on commit f72e781

Please sign in to comment.