fix(LocalAuth): logout method (#1267)

The logout method was trying to use a function call passing the "dataDir" as the "this" reference
This commit is contained in:
Fábio Dias
2022-03-01 23:27:29 -03:00
committed by Pedro Lopez
parent c45fae5c15
commit f88bd274be

View File

@@ -44,7 +44,7 @@ class LocalAuth extends BaseAuthStrategy {
async logout() {
if (this.userDataDir) {
return (fs.rmSync ? fs.rmSync : fs.rmdirSync).call(this.userDataDir, { recursive: true });
return (fs.rmSync ? fs.rmSync : fs.rmdirSync).call(this, this.userDataDir, { recursive: true });
}
}