title: Get all posts by a group of users ordered by timestamp
body: <p>I have three models: a User, a Post, and a Follow, which records when a user followed another user.  I want to show all the posts by users that the current user follows.  The list of posts should be ordered by timestamp.  However, the list seems to be grouped by user id, then ordered by timestamp.  How can I get all the posts by the followed users ordered only by timestamp?</p>
  
  <pre><code>followed_users = Follow.query.filter_by(follower_id=current_user.id).all()
  followed_posts = []
  for i in followed_users:
      followed_posts.extend(Post.query.filter(Post.author == i.followed_id).order_by(Post.timestamp.desc()).all())
  </code></pre>