File tree Expand file tree Collapse file tree 2 files changed +3
-8
lines changed
tap-snapshots/test/lib/commands Expand file tree Collapse file tree 2 files changed +3
-8
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,6 @@ exports[`test/lib/commands/shrinkwrap.js TAP with hidden lockfile ancient > must
16
16
},
17
17
"config": {},
18
18
"shrinkwrap": {
19
- "name": "prefix",
20
19
"lockfileVersion": 1,
21
20
"requires": true
22
21
},
@@ -40,7 +39,6 @@ exports[`test/lib/commands/shrinkwrap.js TAP with hidden lockfile ancient upgrad
40
39
"lockfile-version": 3
41
40
},
42
41
"shrinkwrap": {
43
- "name": "prefix",
44
42
"lockfileVersion": 3,
45
43
"requires": true,
46
44
"packages": {}
@@ -65,7 +63,6 @@ exports[`test/lib/commands/shrinkwrap.js TAP with hidden lockfile existing > mus
65
63
},
66
64
"config": {},
67
65
"shrinkwrap": {
68
- "name": "prefix",
69
66
"lockfileVersion": 2,
70
67
"requires": true,
71
68
"packages": {}
@@ -90,7 +87,6 @@ exports[`test/lib/commands/shrinkwrap.js TAP with hidden lockfile existing downg
90
87
"lockfile-version": 1
91
88
},
92
89
"shrinkwrap": {
93
- "name": "prefix",
94
90
"lockfileVersion": 1,
95
91
"requires": true
96
92
},
@@ -116,7 +112,6 @@ exports[`test/lib/commands/shrinkwrap.js TAP with hidden lockfile existing upgra
116
112
"lockfile-version": 3
117
113
},
118
114
"shrinkwrap": {
119
- "name": "prefix",
120
115
"lockfileVersion": 3,
121
116
"requires": true,
122
117
"packages": {}
@@ -135,7 +130,6 @@ exports[`test/lib/commands/shrinkwrap.js TAP with nothing ancient > must match s
135
130
"localPrefix": {},
136
131
"config": {},
137
132
"shrinkwrap": {
138
- "name": "prefix",
139
133
"lockfileVersion": 3,
140
134
"requires": true,
141
135
"packages": {}
@@ -154,7 +148,6 @@ exports[`test/lib/commands/shrinkwrap.js TAP with nothing ancient upgrade > must
154
148
"lockfile-version": 3
155
149
},
156
150
"shrinkwrap": {
157
- "name": "prefix",
158
151
"lockfileVersion": 3,
159
152
"requires": true,
160
153
"packages": {}
Original file line number Diff line number Diff line change @@ -970,7 +970,9 @@ class Shrinkwrap {
970
970
#buildLegacyLockfile ( node , lock , path = [ ] ) {
971
971
if ( node === this . tree ) {
972
972
// the root node
973
- lock . name = node . packageName || node . name
973
+ if ( node . packageName ) {
974
+ lock . name = node . packageName
975
+ }
974
976
if ( node . version ) {
975
977
lock . version = node . version
976
978
}
You can’t perform that action at this time.
0 commit comments