Skip to content

Commit

Permalink
fix author query
Browse files Browse the repository at this point in the history
  • Loading branch information
matfish3 committed Nov 24, 2021
1 parent 0cb0393 commit afdf5aa
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
# Release Notes for Blogify

### Unreleased - 2021-11-24
### Fixed
- Fixed author query

### Added
- Added optional post views field to allow sorting by popularity
### Changed
- Refactored code
- Seeding: Randomize author

## 1.0.6 - 2021-11-23
### Improved
Expand Down
2 changes: 1 addition & 1 deletion src/behaviors/AuthorPostsBehavior.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ class AuthorPostsBehavior extends Behavior
{
public function getPosts()
{
return Entry::find()->section(Handles::CHANNEL)->authorId($this->owner->id);
return Entry::find()->section(Handles::CHANNEL)->where('authorId='.$this->owner->id);
}
}

0 comments on commit afdf5aa

Please sign in to comment.