Skip to content

Commit 3ef3402

Browse files
refactor(guardObjectKey): remove default value from type variable Obj
1 parent a0ec36e commit 3ef3402

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/type/src/guard/lib/guard-object-key.func.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,5 @@ import { ResultCallback } from '../../type/result-callback.type';
1111
* @returns A `boolean` indicating whether or not the `value` is an `object` of a generic `Obj` containing the `key`.
1212
*/
1313
export const guardObjectKey: GuardObjectKey =
14-
<Obj = object>(value: Obj, key: keyof Obj | (keyof Obj)[], callback?: ResultCallback): value is Obj =>
14+
<Obj>(value: Obj, key: keyof Obj | (keyof Obj)[], callback?: ResultCallback): value is Obj =>
1515
isObjectKey<Obj>(value, key, callback);
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
import { ResultCallback } from '../../type/result-callback.type';
2-
export type GuardObjectKey = <Obj = object>(value: Obj, key: keyof Obj | (keyof Obj)[], callback?: ResultCallback) => value is Obj;
2+
export type GuardObjectKey = <Obj>(value: Obj, key: keyof Obj | (keyof Obj)[], callback?: ResultCallback) => value is Obj;
33

44

0 commit comments

Comments
 (0)