diff options
-rw-r--r-- | blavote.go | 2 | ||||
-rw-r--r-- | poll.go | 2 |
2 files changed, 2 insertions, 2 deletions
@@ -14,7 +14,7 @@ var version string func main() { - version = "0.7.1" + version = "0.7.2" //Command line arguments var opts struct { @@ -148,7 +148,7 @@ func hasUserVotedInPoll(db *sqlite3.Conn, poll Poll, user User) bool { func getRecentPolls(db *sqlite3.Conn) ([]Poll, error) { - sql := "SELECT * FROM polls LIMIT 5" + sql := "SELECT * FROM polls ORDER BY id DESC LIMIT 5" s, err := db.Query(sql) row := make(sqlite3.RowMap) var polls = make([]Poll, 5) |