diff --git a/pkg/hydrator/hydrator.go b/pkg/hydrator/hydrator.go index 472707b..aa7ad47 100644 --- a/pkg/hydrator/hydrator.go +++ b/pkg/hydrator/hydrator.go @@ -251,6 +251,8 @@ func (h *Hydrator) flattenFullProfile(profile *bsky.ActorDefs_ProfileViewDetaile } func (h *Hydrator) flattenFacets(facets []*bsky.RichtextFacet) (hashtags []string, urls []string) { + hashtags = []string{} + urls = []string{} if facets != nil { for _, facet := range facets { if facet != nil { diff --git a/pkg/output/bq/schema/schema.go b/pkg/output/bq/schema/schema.go index 31007c3..7f6d72c 100644 --- a/pkg/output/bq/schema/schema.go +++ b/pkg/output/bq/schema/schema.go @@ -276,6 +276,16 @@ func GetSchema() bigquery.Schema { "name": "RepostCount", "type": "INTEGER" }, + { + "mode": "REPEATED", + "name": "Hashtags", + "type": "STRING" + }, + { + "mode": "REPEATED", + "name": "URLs", + "type": "STRING" + }, { "name": "Text", "type": "STRING" @@ -399,6 +409,16 @@ func GetSchema() bigquery.Schema { "name": "ReplyParentCID", "type": "STRING" }, + { + "mode": "REPEATED", + "name": "Hashtags", + "type": "STRING" + }, + { + "mode": "REPEATED", + "name": "URLs", + "type": "STRING" + }, { "name": "Text", "type": "STRING" @@ -566,6 +586,16 @@ func GetSchema() bigquery.Schema { "name": "RepostCount", "type": "INTEGER" }, + { + "mode": "REPEATED", + "name": "Hashtags", + "type": "STRING" + }, + { + "mode": "REPEATED", + "name": "URLs", + "type": "STRING" + }, { "name": "Text", "type": "STRING"