[@types/ioredis] hgetall returns object (#40966)

* [@types/ioredis] hgetall returns object

changed type of hgetall result from string[] to object

* hgetall returns { [key: string]: string | number }

changed hgetall result type from object to { [key: string]: string | number }
This commit is contained in:
Shayan Javani
2019-12-13 09:27:55 +00:00
committed by Orta
parent 3681030fea
commit e6f3bd1b96
+3 -3
View File
@@ -323,8 +323,8 @@ declare namespace IORedis {
hvals(key: KeyType, callback: (err: Error, res: string[]) => void): void;
hvals(key: KeyType): Promise<string[]>;
hgetall(key: KeyType, callback: (err: Error, res: string[]) => void): void;
hgetall(key: KeyType): Promise<string[]>;
hgetall(key: KeyType, callback: (err: Error, res: { [key: string]: string | number }) => void): void;
hgetall(key: KeyType): Promise<{ [key: string]: string | number }>;
hexists(key: KeyType, field: string, callback: (err: Error, res: BooleanResponse) => void): void;
hexists(key: KeyType, field: string): Promise<BooleanResponse>;
@@ -739,7 +739,7 @@ declare namespace IORedis {
hvals(key: KeyType, callback?: (err: Error, res: string[]) => void): Pipeline;
hgetall(key: KeyType, callback?: (err: Error, res: string[]) => void): Pipeline;
hgetall(key: KeyType, callback?: (err: Error, res: { [key: string]: string | number }) => void): Pipeline;
hexists(key: KeyType, field: string, callback?: (err: Error, res: BooleanResponse) => void): Pipeline;