Skip to content

Commit

Permalink
Fix too many rows exception
Browse files Browse the repository at this point in the history
  • Loading branch information
gunnarvelle committed Nov 29, 2024
1 parent d764970 commit 8018290
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,7 @@ trait DraftRepository {
}

def withSlug(slug: String)(implicit session: DBSession): Option[Draft] = articleWhere(
sqls"ar.slug=${slug.toLowerCase}"
sqls"ar.slug=${slug.toLowerCase} ORDER BY revision DESC LIMIT 1"
)

def slugExists(slug: String, articleId: Option[Long])(implicit
Expand Down

0 comments on commit 8018290

Please sign in to comment.