Skip to content

Commit c84110c

Browse files
committed
Fix doesn't execute the db/languages.sql to initialize the languages table in new server
1 parent 82a5122 commit c84110c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmd/goatcounter/main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ func connectDB(connect, dbConn string, migrate []string, create, dev bool) (zdb.
217217

218218
// Load languages.
219219
var c int
220-
err = db.Get(context.Background(), &c, `select count(*) from languages`)
220+
err = db.Get(context.Background(), &c, `select count(*) from languages where NOT (iso_639_3 = "" AND name = "(unknown)")`)
221221
// Ignore the error intentionally; not being able to select from the
222222
// languages table here to populate it (usually because it doesn't exist
223223
// yet) shouldn't be a fatal error. If there's some other error then the

0 commit comments

Comments
 (0)