Download Latest Version Version 0.4.zip (51.6 kB)
Email in envelope

Get an email when there's a new version of MultipeerKit

Home / 0.3.0
Name Modified Size InfoDownloads / Week
Parent folder
0.3.0.tar.gz 2020-07-08 38.6 kB
0.3.0.zip 2020-07-08 71.9 kB
README.md 2020-07-08 490 Bytes
Totals: 3 Items   111.0 kB 0

Receiver blocks now receive the Peer the message was sent from. This is a breaking change to the API, but it's very easy to account for in your code.

If you were previously doing something like this:

:::swift
transceiver.receive(SomeCodableThing.self) { payload in
    // handle
}

All you have to do is ignore the sender parameter in the closure, like so:

:::swift
transceiver.receive(SomeCodableThing.self) { payload, _ in
    // handle
}
Source: README.md, updated 2020-07-08