all repos — honk @ 2554baee873ab0d70f7b141870cf328b27562152

my fork of honk

going to need userid in zonkers table too
Ted Unangst tedu@tedunangst.com
Fri, 19 Apr 2019 22:34:39 -0400
commit

2554baee873ab0d70f7b141870cf328b27562152

parent

e31e7c88cae84bdc20136e2f1209a4abc1d88c85

2 files changed, 2 insertions(+), 2 deletions(-)

jump to
M schema.sqlschema.sql

@@ -4,7 +4,7 @@ create table donks (honkid integer, fileid integer);

create table files(fileid integer primary key, xid text, name text, url text, media text, content blob); create table honkers (honkerid integer primary key, userid integer, name text, xid text, flavor text, pubkey text); create table xonkers (xonkerid integer primary key, xid text, ibox text, obox text, sbox text, pubkey text); -create table zonkers (zonkerid integer primary key, name text, wherefore text); +create table zonkers (zonkerid integer primary key, userid integer, name text, wherefore text); create table doovers(dooverid integer primary key, dt text, tries integer, username text, rcpt text, msg blob); create index idx_honksxid on honks(xid);
M upgradedb.goupgradedb.go

@@ -49,7 +49,7 @@ doordie(db, "create table xonkers (xonkerid integer primary key, xid text, ibox text, obox text, sbox text, pubkey text)")

doordie(db, "insert into xonkers (xid, ibox, obox, sbox, pubkey) select xid, '', '', '', pubkey from honkers where flavor = 'key'") doordie(db, "delete from honkers where flavor = 'key'") doordie(db, "create index idx_xonkerxid on xonkers(xid)") - doordie(db, "create table zonkers (zonkerid integer primary key, name text, wherefore text)") + doordie(db, "create table zonkers (zonkerid integer primary key, userid integer, name text, wherefore text)") doordie(db, "create index idx_zonkersname on zonkers(name)") doordie(db, "update config set value = 3 where key = 'dbversion'") fallthrough