Category data now includes their subcategories. Categories can now be requested by ID in a prettier way.

This commit is contained in:
2021-09-09 11:34:06 -05:00
parent 20a6365159
commit 871484a8e5
4 changed files with 147 additions and 57 deletions
+2
View File
@@ -7,6 +7,8 @@ import (
_ "github.com/lib/pq"
)
//TODO: maybe we can do the whole databaase connection things on application start and panic right away
//if we can't connect to the database.
func getSQLConnection() *sql.DB {
//Note: The postgres driver seems to get confused when no password is supplied, so omit it in the connection sting.
//https://rajyavardhan.medium.com/when-you-get-relation-does-not-exist-in-postgres-7ffb0c3c674b