title: Javafx (Node) getUserDate() or getProperties() returns a none null value and throws NullPointerException
body: <p>Here is the code that set the user data.</p>
  
  <pre><code>   FXMLLoader loader = new FXMLLoader(getClass().getResource(page.toString()));
     Parent node = (Parent) loader.load();
     loader.getController().setParent(handler);
     controllers.put(page.name(), loader.getController());
     controller = controllers.get(page.name());
     node.setUserData(page.name());
     node.getProperties().put("page", page.name());
  </code></pre>
  
  <p>the variable page is an Enum object, I'm using the name 'page.name()' as the user data</p>
  
  <p>Here is the code that gets the user data:</p>
  
  <pre><code> while (iterator.hasNext()) {
          Node node = iterator.next();
          String name = node.getProperties().get("page").toString();
          System.out.println(name);
          ....
      }
  </code></pre>
  
  <p>now this what happens:
  the <strong>System.out.println(name);</strong> prints out the user data correctly,
  and then I get a <strong>NullPointException</strong> pointing to</p>
  
  <pre><code>String name = node.getProperties().get("page").toString();
  </code></pre>
  
  <p>the point is <strong>System.out.println(name);</strong> that prints the user date
  prints it correct.</p>
  
  <p>What's going on here?</p>