Skip to content

Commit 12acbd2

Browse files
committed
Implemented delegate method for when the browser fails to browse for peers and included a log message about the missing Info.plist keys
1 parent d67f15a commit 12acbd2

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

Sources/MultipeerKit/Internal API/MultipeerConnection.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,10 @@ extension MultipeerConnection: MCNearbyServiceBrowserDelegate {
214214
discoveredPeers[peerID] = nil
215215
}
216216

217+
func browser(_ browser: MCNearbyServiceBrowser, didNotStartBrowsingForPeers error: Error) {
218+
os_log("The multipeer connection failed to start browsing for peers. This could be due to missing keys in your app's Info.plist, check out the documentation at http://github.com/insidegui/MultipeerKit for more information. Error: %{public}@", log: log, type: .fault, String(describing: error))
219+
}
220+
217221
}
218222

219223
// MARK: - Advertiser delegate

0 commit comments

Comments
 (0)