Set the type of the node if the user specifies it