Skip to main content

talawa-api / Exports / utilities/userFamilyAdminCheck

Module: utilities/userFamilyAdminCheck

Table of contents

Functions

Functions

adminCheck

adminCheck(userId, userFamily): Promise<void>

If the current user is an admin of the organisation, this function returns true otherwise it returns false.

Parameters

NameTypeDescription
userIdstring | ObjectIdCurrent user id.
userFamilyInterfaceUserFamilyuserFamily data of InterfaceuserFamily type.

Returns

Promise<void>

True or False.

Remarks

This is a utility method.

Defined in

src/utilities/userFamilyAdminCheck.ts:14