UNPKG

@silverwind/ioredis-mock

Version:

This library emulates ioredis by performing all operations in-memory.

17 lines (14 loc) 306 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.hmget = hmget; function hmget(key, ...fields) { const hash = this.data.get(key); return fields.map(field => { if (!hash || hash[field] === undefined) { return null; } return hash[field]; }); }