mirror of
https://github.com/Llewellynvdm/nativefier.git
synced 2024-11-10 23:31:10 +00:00
fix protocol cli
This commit is contained in:
parent
7464ba56a3
commit
46b0596eb8
6
cli.js
6
cli.js
@ -5,11 +5,11 @@ var packager = require('./')
|
||||
args.dir = args._[0]
|
||||
args.name = args._[1]
|
||||
|
||||
var protocolSchemes = args.protocol
|
||||
var protocolNames = args['protocol-names']
|
||||
var protocolSchemes = [].concat(args.protocol || [])
|
||||
var protocolNames = [].concat(args['protocol-name'] || [])
|
||||
|
||||
if (protocolSchemes && protocolNames && protocolNames.length === protocolSchemes.length) {
|
||||
args.protocol = protocolSchemes.map(function (scheme, i) {
|
||||
args.protocols = protocolSchemes.map(function (scheme, i) {
|
||||
return {schemes: [scheme], name: protocolNames[i]}
|
||||
})
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user