#1616·ioredis

如何在不使用丑陋的索引的情况下从管道中获取结果?

作者: SalesFeed创建于 2022年7月1日更新于 2026年9月25日
标签stale

I find it difficult to get a good grip on the results returned from pipelines. For example: if I push 4 commands into a pipeline, then execute it, ioredis returns an array in which I have to use an index to get the result from one of the commands. To solve this problem, I tried the callback approach, which seems to work: