Allow actions to have an argument

This commit is contained in:
Nick O'Leary 2018-10-26 23:08:27 +01:00
parent 49fe13f22f
commit 3fcacd8339
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
1 changed files with 2 additions and 2 deletions

View File

@ -12,9 +12,9 @@ RED.actions = (function() {
function getAction(name) {
return actions[name];
}
function invokeAction(name) {
function invokeAction(name,args) {
if (actions.hasOwnProperty(name)) {
actions[name]();
actions[name](args);
}
}
function listActions() {