+4
-4
Dockerfile
+4
-4
Dockerfile
······
+2
-1
cmd/atshorter/main.go
+2
-1
cmd/atshorter/main.go
···
+2
-4
consumer.go
+2
-4
consumer.go
······-err := h.store.CreateURL(event.Commit.RKey, record.URL, event.Did, record.CreatedAt.UnixMilli())+err := h.store.CreateURL(event.Commit.RKey, record.URL, event.Did, record.Origin, record.CreatedAt.UnixMilli())
+8
-7
database/urls.go
+8
-7
database/urls.go
······-sql := `INSERT INTO urls (id, url, did, createdAt) VALUES (?, ?, ?, ?) ON CONFLICT(id) DO NOTHING;`+sql := `INSERT INTO urls (id, url, did, originHost, createdAt) VALUES (?, ?, ?, ?, ?) ON CONFLICT(id) DO NOTHING;`······+if err := rows.Scan(&shortURL.ID, &shortURL.URL, &shortURL.Did, &shortURL.OriginHost); err != nil {······
+1
-1
html/home.html
+1
-1
html/home.html
+10
-5
server.go
+10
-5
server.go
·········func NewServer(host string, port string, store Store, oauthClient *oauth.ClientApp, httpClient *http.Client) (*Server, error) {···
+12
-22
short_url_handler.go
+12
-22
short_url_handler.go
······-slog.Error("getting URL record from PDS", "error", err, "did", shortURL.Did, "id", shortURL.ID)-// TODO: use the host from the record to check that it was created using this host - otherwise it's a short URL·········