Commit aef57c91 authored by ioedeveloper's avatar ioedeveloper

Update error logs

parent 6a8a134a
...@@ -108,8 +108,8 @@ module.exports = class Filepanel extends ViewPlugin { ...@@ -108,8 +108,8 @@ module.exports = class Filepanel extends ViewPlugin {
* @param { name: string, type?: string[], path?: string[], extension?: string[], pattern?: string[] } * @param { name: string, type?: string[], path?: string[], extension?: string[], pattern?: string[] }
*/ */
registerContextMenuItem (item, callback) { registerContextMenuItem (item, callback) {
if (!item.name || !callback) return console.error('menu name and item is mandatory') if (!item.name || !callback) return console.error('menu name and callback is mandatory')
if (!item.type && !item.path && !item.extension && !item.pattern) return console.error('invalid menu match criteria provided') if (!item.type && !item.path && !item.extension && !item.pattern) return console.error('invalid file matching criteria provided')
item.action = callback item.action = callback
this.registeredMenuItems = [...this.registeredMenuItems, item] this.registeredMenuItems = [...this.registeredMenuItems, item]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment