Methods
add
- add(username: string, password: password, admin: boolean, callback?: (error: Error | null, success?: boolean) => void): Promise<boolean>
-
Parameters
-
username: string
-
-
admin: boolean
-
Optional callback: (error: Error | null, success?: boolean) => void
-
- (error: Error | null, success?: boolean): void
-
Parameters
-
error: Error | null
-
Optional success: boolean
Returns void
Returns Promise<boolean>
list
- list(callback?: (error: Error | null, users?: User[]) => void): Promise<User[]>
-
Parameters
-
Optional callback: (error: Error | null, users?: User[]) => void
-
- (error: Error | null, users?: User[]): void
-
Parameters
-
error: Error | null
-
Optional users: User[]
Returns void
Returns Promise<User[]>
remove
- remove(username: string, callback?: (error: Error | null, removed?: boolean) => void): Promise<boolean>
-
Parameters
-
username: string
-
Optional callback: (error: Error | null, removed?: boolean) => void
-
- (error: Error | null, removed?: boolean): void
-
Parameters
-
error: Error | null
-
Optional removed: boolean
Returns void
Returns Promise<boolean>
Create a new user for Dicoogle.