From d2beda0128d380cb2e6322049300427b75cea692 Mon Sep 17 00:00:00 2001 From: Emile Fugulin Date: Wed, 17 Jun 2020 14:02:28 -0400 Subject: [PATCH] fix(interface): Type -> TypeName and Field -> FieldName --- src/builders.ts | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/builders.ts b/src/builders.ts index 5dc99be7..28c86443 100644 --- a/src/builders.ts +++ b/src/builders.ts @@ -162,16 +162,18 @@ export const deny = new RuleFalse(); * */ export const generic = (rule: ShieldRule) => < - Type extends string, - Field extends string ->(): ShieldRule => rule; + TypeName extends string, + FieldName extends string +>(): ShieldRule => rule; /** * * Helper for partial rules * */ -export const partial = (rule: ShieldRule) => < - T extends Type, // NOTE: It would be best to do someting with this type - Field extends string ->(): ShieldRule => rule; +export const partial = ( + rule: ShieldRule +) => < + T extends TypeName, // NOTE: It would be best to do something with this type + FieldName extends string +>(): ShieldRule => rule;