Implement downloading videos

This commit is contained in:
2024-06-17 14:20:45 +02:00
parent f0b85f6f64
commit 78455cceaa
2 changed files with 61 additions and 10 deletions

View File

@@ -45,12 +45,9 @@ func main() {
listener.Collections = []string{COLLECTION_NAME}
listener.initialize()
for {
select {
case event := <-listener.Create:
log.Printf("Create event: %+v\n", event)
go Download(event)
}
for event := range listener.Create {
log.Printf("Create event: %+v\n", event)
go Download(event)
}
time.Sleep(1 * time.Hour)