fix crash on setting nwUserAgent attribute
don't use node's OnMessage for now