Cleaned the input string a bit
Extracted the application of an update into it's own method

I also changed the update, so that it receives the ID, not the node.
This makes it easier to implement when the node does not exist (for
example I am adding a new node).
Added a test to add a new global variable
The getNode method can now create a new one when it can't find it

This treated the case when I create a new node