| Conditions | 6 | 
| Total Lines | 23 | 
| Code Lines | 15 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Changes | 0 | ||
| 1 | package producer | ||
| 27 | func (p *DictionaryProducer) Produce(ctx context.Context) <-chan scan.Target { | ||
| 28 | targets := make(chan scan.Target, 10) | ||
| 29 | |||
| 30 | 	go func() { | ||
| 31 | defer close(targets) | ||
| 32 | |||
| 33 | 		for _, entry := range p.dictionary { | ||
| 34 | 			for _, method := range p.methods { | ||
| 35 | 				select { | ||
| 36 | case <-ctx.Done(): | ||
| 37 | return | ||
| 38 | default: | ||
| 39 | 					targets <- scan.Target{ | ||
| 40 | Path: entry, | ||
| 41 | Method: method, | ||
| 42 | Depth: p.depth, | ||
| 43 | } | ||
| 44 | } | ||
| 45 | } | ||
| 46 | } | ||
| 47 | }() | ||
| 48 | |||
| 49 | return targets | ||
| 50 | } | ||
| 51 |