0
0

Merge pull request #247 from pmezard/remove-update-goroutine

upside_down: no need for a goroutine to enqueue AnalysisWork
This commit is contained in:
Marty Schoch 2015-10-16 10:15:55 -04:00
commit e6d0fc8d95

View File

@ -265,9 +265,7 @@ func (udc *UpsideDownCouch) Update(doc *document.Document) (err error) {
resultChan := make(chan *index.AnalysisResult)
aw := index.NewAnalysisWork(udc, doc, resultChan)
// put the work on the queue
go func() {
udc.analysisQueue.Queue(aw)
}()
udc.analysisQueue.Queue(aw)
// wait for the result
result := <-resultChan