ldap-ts-client
Advanced tools
Comparing version 0.9.1-beta3 to 0.9.1-beta4
@@ -17,6 +17,2 @@ "use strict"; | ||
this.baseDN = config.baseDN; | ||
this.client = ldapjs_1.default.createClient({ | ||
url: config.ldapServerUrl, | ||
log: this.config.logger, | ||
}); | ||
} | ||
@@ -26,5 +22,10 @@ /** @return a connected ldap client that is useful for use flexibility of [ldap.js](http://ldapjs.org/) directly. */ | ||
var _a; | ||
console.log(`File: index.ts,`, `Line: 97 => bind`); | ||
console.log(`File: index.ts,`, `Line: 93 => bind`); | ||
(_a = this.logger) === null || _a === void 0 ? void 0 : _a.trace("bind()"); | ||
return new Promise((resolve, reject) => { | ||
console.log(`File: index.ts,`, `Line: 97 => `); | ||
this.client = ldapjs_1.default.createClient({ | ||
url: this.config.ldapServerUrl, | ||
log: this.config.logger, | ||
}); | ||
this.client.bind(this.config.user, this.config.pass, (err, result) => { | ||
@@ -31,0 +32,0 @@ if (err) { |
{ | ||
"name": "ldap-ts-client", | ||
"version": "0.9.1-beta3", | ||
"version": "0.9.1-beta4", | ||
"description": "Type-safe LDAP client written in typescript", | ||
@@ -5,0 +5,0 @@ "repository": { |
@@ -84,6 +84,2 @@ import ldap, { SearchOptions, Control, SearchEntryObject } from "ldapjs"; | ||
this.baseDN = config.baseDN; | ||
this.client = ldap.createClient({ | ||
url: config.ldapServerUrl, | ||
log: this.config.logger, | ||
}); | ||
} | ||
@@ -98,6 +94,13 @@ | ||
public async bind(): Promise<ldap.Client> { | ||
console.log(`File: index.ts,`, `Line: 97 => bind`); | ||
console.log(`File: index.ts,`, `Line: 93 => bind`); | ||
this.logger?.trace("bind()"); | ||
return new Promise((resolve, reject) => { | ||
console.log(`File: index.ts,`, `Line: 97 => `); | ||
this.client = ldap.createClient({ | ||
url: this.config.ldapServerUrl, | ||
log: this.config.logger, | ||
}); | ||
this.client.bind(this.config.user, this.config.pass, (err, result) => { | ||
@@ -104,0 +107,0 @@ if (err) { |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
58283
1119