changed insertRows to queue instead of chan