Changed when/node call to a simple function call
Merge pull request #492 from dapetcu21/v3

Changed when/node call to a simple function call