mirror of
https://github.com/derfenix/webarchive.git
synced 2026-03-11 12:41:54 +03:00
Refactoring
This commit is contained in:
@@ -75,6 +75,13 @@ func (p *Page) Process(ctx context.Context, processor Processor) {
|
||||
innerWG := sync.WaitGroup{}
|
||||
innerWG.Add(len(p.Formats))
|
||||
|
||||
meta, err := processor.GetMeta(ctx, p.URL)
|
||||
if err != nil {
|
||||
p.Meta.Error = err.Error()
|
||||
} else {
|
||||
p.Meta = meta
|
||||
}
|
||||
|
||||
for _, format := range p.Formats {
|
||||
go func(format Format) {
|
||||
defer innerWG.Done()
|
||||
|
||||
Reference in New Issue
Block a user