mirror of
https://github.com/verdaccio/verdaccio.git
synced 2024-12-30 22:34:10 -05:00
fix wrong htpasswd file location (#3750)
This commit is contained in:
parent
f86f9244f2
commit
09753cc1fa
2 changed files with 7 additions and 2 deletions
5
.changeset/silly-moose-watch.md
Normal file
5
.changeset/silly-moose-watch.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
'verdaccio-htpasswd': patch
|
||||
---
|
||||
|
||||
fix wrong htpasswd file location
|
|
@ -1,6 +1,6 @@
|
|||
import buildDebug from 'debug';
|
||||
import fs from 'fs';
|
||||
import { dirname, join, resolve } from 'path';
|
||||
import { dirname, resolve } from 'path';
|
||||
|
||||
import { pluginUtils } from '@verdaccio/core';
|
||||
import { unlockFile } from '@verdaccio/file-locking';
|
||||
|
@ -90,7 +90,7 @@ export default class HTPasswd
|
|||
throw new Error('should specify "file" in config');
|
||||
}
|
||||
debug('config path: %s', options?.config?.configPath);
|
||||
this.path = join(resolve(dirname(options?.config?.configPath ?? '')), file);
|
||||
this.path = resolve(dirname(options?.config?.configPath), file);
|
||||
this.logger.info({ file: this.path }, 'using htpasswd file: @{file}');
|
||||
debug('htpasswd path:', this.path);
|
||||
if (config.slow_verify_ms) {
|
||||
|
|
Loading…
Reference in a new issue