Fixing WebSocket constructor

Use NativeFunction constructor instead of usial constructor