Update getNode return type

Update getNode return type, since the 'id' may not map to a valid node. In this case, node-red will return null.
This commit is contained in:
Bernardo Belchior
2019-04-15 18:18:31 +01:00
committed by GitHub
parent 802806bcfe
commit 2bcb843faf

View File

@@ -173,9 +173,9 @@ export interface Nodes {
* node, this call is used to get access to the running
* instance.
* @param id - the id of the node.
* @return - the node matching the given id.
* @return - the node matching the given id, or null if it does not exist.
*/
getNode(id: NodeId): Node;
getNode(id: NodeId): Node | null;
/**
* Cycle through all node definition objects.
*