Skip to content

Commit

Permalink
feat(modules): added core_user_delete_users function
Browse files Browse the repository at this point in the history
  • Loading branch information
Luke Carr committed May 21, 2020
1 parent af65809 commit fe7d1d0
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/modules/core/user/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,17 @@ export default class UserModule extends Module {
return response1;
}

/**
* Deletes users from the Moodle site.
*
* @param users The IDs of the users to delete.
*/
public async deleteUsers(...users: number[]): Promise<FunctionResponse> {
return (await this.get("core_user_delete_users", {
userids: users,
})) as FunctionResponse;
}

/**
* Searches for users on the Moodle site that match
* the provided crtieria.
Expand Down

0 comments on commit fe7d1d0

Please sign in to comment.