diff options
| author | Samuel Johnson <[email protected]> | 2025-11-25 19:47:20 -0500 |
|---|---|---|
| committer | Samuel Johnson <[email protected]> | 2025-11-25 19:47:20 -0500 |
| commit | 3c237fc659c2829042407697ca7aa3e1442a5719 (patch) | |
| tree | 6557b2faa27eb9880ef96c8755bed3f8a461d2ae /internal/dbmigrations.go | |
| parent | 368a462bc744d8e9084eacfaddeb9afcaf7f7133 (diff) | |
Add post editing interface
Diffstat (limited to 'internal/dbmigrations.go')
| -rw-r--r-- | internal/dbmigrations.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/dbmigrations.go b/internal/dbmigrations.go index e6c11ff..d5f4836 100644 --- a/internal/dbmigrations.go +++ b/internal/dbmigrations.go @@ -33,7 +33,7 @@ func Migrate (db *sql.DB, webmaster string, passOne string, passTwo string) { _, table_check = db.Query("SELECT * FROM posts;") if table_check != nil { - _, err := db.Exec("CREATE TABLE posts (id SERIAL PRIMARY KEY, user_id INTEGER REFERENCES logins(id), time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, content TEXT NOT NULL);") + _, err := db.Exec("CREATE TABLE posts (id SERIAL PRIMARY KEY, user_id INTEGER REFERENCES logins(id), time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, brief TEXT NOT NULL, content TEXT NOT NULL);") if err != nil { fmt.Fprintf(os.Stderr, "Unable to create posts table: %v\n", err) os.Exit(1) |
