Access directly on options object
This commit is contained in:
parent
d200cf2e77
commit
5f862effaa
1 changed files with 2 additions and 2 deletions
|
@ -177,7 +177,7 @@ module.exports = {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let {buttons, cancelId, defaultId, detail, icon, message, title, type, normalizeAccessKeys} = options
|
let {buttons, cancelId, defaultId, detail, icon, message, title, type} = options
|
||||||
|
|
||||||
if (type == null) {
|
if (type == null) {
|
||||||
type = 'none'
|
type = 'none'
|
||||||
|
@ -194,7 +194,7 @@ module.exports = {
|
||||||
throw new TypeError('Buttons must be an array')
|
throw new TypeError('Buttons must be an array')
|
||||||
}
|
}
|
||||||
|
|
||||||
if (normalizeAccessKeys) {
|
if (options.normalizeAccessKeys) {
|
||||||
buttons = buttons.map(normalizeAccessKey)
|
buttons = buttons.map(normalizeAccessKey)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue