mirror of
https://github.com/verdaccio/verdaccio.git
synced 2024-11-08 23:25:51 +01:00
fix: avoid warning "time for version x already exists" (#4577)
* fix: avoid warning "time for version x already exists" * changeset
This commit is contained in:
parent
d5d96f0868
commit
f967a69ad3
5
.changeset/quick-buses-scream.md
Normal file
5
.changeset/quick-buses-scream.md
Normal file
@ -0,0 +1,5 @@
|
||||
---
|
||||
'@verdaccio/store': patch
|
||||
---
|
||||
|
||||
fix: avoid warning "time for version x already exists"
|
@ -1063,7 +1063,7 @@ class Storage {
|
||||
|
||||
const hasPackageInStorage = await this.hasPackage(name);
|
||||
if (!hasPackageInStorage) {
|
||||
await this.createNewLocalCachePackage(name, versionToPublish);
|
||||
await this.createNewLocalCachePackage(name);
|
||||
successResponseMessage = API_MESSAGE.PKG_CREATED;
|
||||
} else {
|
||||
successResponseMessage = API_MESSAGE.PKG_CHANGED;
|
||||
@ -1363,7 +1363,7 @@ class Storage {
|
||||
* @param name name of the package
|
||||
* @returns
|
||||
*/
|
||||
private async createNewLocalCachePackage(name: string, latestVersion: string): Promise<void> {
|
||||
private async createNewLocalCachePackage(name: string): Promise<void> {
|
||||
const storage: pluginUtils.StorageHandler = this.getPrivatePackageStorage(name);
|
||||
|
||||
if (!storage) {
|
||||
@ -1377,7 +1377,6 @@ class Storage {
|
||||
time: {
|
||||
created: currentTime,
|
||||
modified: currentTime,
|
||||
[latestVersion]: currentTime,
|
||||
},
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user