mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
revert to more graceful template structure check (#12702)
This commit is contained in:
@@ -167,7 +167,7 @@ Menu.setApplicationMenu = function (menu) {
|
||||
}
|
||||
|
||||
Menu.buildFromTemplate = function (template) {
|
||||
if (!(template instanceof Array)) {
|
||||
if (!Array.isArray(template)) {
|
||||
throw new TypeError('Invalid template for Menu')
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user