Skip to content

Commit e6eacda

Browse files
2nthonylevy9527
authored andcommitted
fix(upgrade): notify.sh 错误
1 parent f3af049 commit e6eacda

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

init.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ function isUpgrade() {
2525
if (isUpgrade()) {
2626
try {
2727
pkg = require(path.join(process.cwd(), 'package.json'))
28-
npmName = pkg.name.replace(/^@[\w]*\//, '')
29-
ownerName = pkg.name.replace(/^@([\w]*)\/[\w]*/, '$1')
28+
npmName = pkg.name.replace(/^@[\w-]*\//, '')
29+
ownerName = pkg.name.replace(/^@([\w-]*)\/[\w-]*/, '$1')
3030
} catch {}
3131
}
3232

0 commit comments

Comments
 (0)