Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Server documentation error #79

Closed
liran opened this issue Sep 12, 2020 · 2 comments
Closed

Server documentation error #79

liran opened this issue Sep 12, 2020 · 2 comments
Labels
bug Something isn't working released

Comments

@liran
Copy link

liran commented Sep 12, 2020

There is an error in the code to start a server.
https://github.com/Rapsssito/react-native-tcp-socket#server

const server = TcpSocket.createServer(function(socket) {
  socket.on('data', (data) => {
    socket.write('Echo server', data);
  });

  socket.on('error', (error) => {
    console.log('An error ocurred with client socket ', error);
  });

  socket.on('close', (error) => {
    console.log('Closed connection with ', socket.address());
  });
}).listen(12345, '0.0.0.0'); // here
// listen({ port: 12345, host: '0.0.0.0' }); // right

This is why #57 appears.

@liran liran added the bug Something isn't working label Sep 12, 2020
@Rapsssito
Copy link
Owner

@liran, thanks! You are right, I will fix it right now.

@Rapsssito Rapsssito reopened this Sep 12, 2020
@Rapsssito Rapsssito changed the title The document has an error Server documentation error Sep 12, 2020
github-actions bot pushed a commit that referenced this issue Sep 12, 2020
## [4.5.1](v4.5.0...v4.5.1) (2020-09-12)

### Bug Fixes

* Fix TCPServer documentation ([d0dcd5b](d0dcd5b)), closes [#79](#79) [#57](#57)
@github-actions
Copy link

🎉 This issue has been resolved in version 4.5.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working released
Projects
None yet
Development

No branches or pull requests

2 participants