Changed name to XmppCodec
This commit is contained in:
parent
56dc1c6e60
commit
eb0bc1b82f
5 changed files with 22 additions and 22 deletions
|
|
@ -2,7 +2,7 @@ use futures::{SinkExt, StreamExt};
|
|||
use tokio::{self, io, net::TcpSocket};
|
||||
use tokio_util::codec::Framed;
|
||||
|
||||
use tokio_xmpp::XMPPCodec;
|
||||
use tokio_xmpp::XmppCodec;
|
||||
|
||||
#[tokio::main]
|
||||
async fn main() -> Result<(), io::Error> {
|
||||
|
|
@ -18,7 +18,7 @@ async fn main() -> Result<(), io::Error> {
|
|||
let (stream, _addr) = listener.accept().await?;
|
||||
|
||||
// Use the `XMPPCodec` to encode and decode frames
|
||||
let mut framed = Framed::new(stream, XMPPCodec::new());
|
||||
let mut framed = Framed::new(stream, XmppCodec::new());
|
||||
|
||||
tokio::spawn(async move {
|
||||
while let Some(packet) = framed.next().await {
|
||||
|
|
|
|||
Loading…
Reference in a new issue