Skip to content

Commit f8a01f3

Browse files
committed
Example updated
1 parent 8615d6f commit f8a01f3

File tree

2 files changed

+158
-158
lines changed

2 files changed

+158
-158
lines changed

examples/tcpsockets/App.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ class App extends React.Component {
4848
socket.on('close', (error) => {
4949
this.updateChatter('server client closed ' + (error ? error : ''));
5050
});
51-
}).listen(serverPort, serverHost, () => {
52-
this.updateChatter('opened server on ' + JSON.stringify(server.address()));
51+
}).listen(serverPort, serverHost, (address) => {
52+
this.updateChatter('opened server on ' + JSON.stringify(address));
5353
});
5454

5555
server.on('error', (error) => {
@@ -63,7 +63,7 @@ class App extends React.Component {
6363
client = TcpSocket.createConnection({
6464
port: serverPort,
6565
host: serverHost,
66-
// localAddress: "127.0.0.1",
66+
localAddress: "127.0.0.1",
6767
// localPort: 20000,
6868
// interface: "wifi"
6969
}, (address) => {

0 commit comments

Comments
 (0)