Last active
May 21, 2018 09:15
-
-
Save joan38/7fcfb253918b110ea766cb4673cc745e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
object Post { | |
implicit val record: Record[Id[Post], Post] = new Record[Id[Post], Post] { | |
val topic = "posts" | |
def key(post: Post): Id[Post] = post.id | |
def timestamp(post: Post): Long = post.updatedOn.toEpochMilli | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment