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

Please fix at url: URL?, #7

Open
Alexandeer opened this issue Oct 21, 2017 · 2 comments
Open

Please fix at url: URL?, #7

Alexandeer opened this issue Oct 21, 2017 · 2 comments

Comments

@Alexandeer
Copy link

Alexandeer commented Oct 21, 2017

Xcode 9, build for iOS 9.2+, class MultipeerConnectivitySession

I made fix for self:

public func session(_ session: MCSession,
                      didFinishReceivingResourceWithName name: String,
                      fromPeer peerID: MCPeerID,
                      at url: URL?,
                      withError err: Error?) {
    if let e = err {
      _receivedResource.on(.next(peerID, name, ResourceState.errored(e)))
      return
    }
    
    if let url = url {
        _receivedResource.on(.next(peerID, name,  ResourceState.finished(url)))
    }
  }
@nathankot
Copy link
Member

Hi @Alexandeer could you please provide a bit more information around the error that you're seeing?

@Alexandeer
Copy link
Author

@nathankot Hi
This method was changed.
https://developer.apple.com/documentation/multipeerconnectivity/mcsessiondelegate/1406984-session

at localURL: URL,

to

at localURL: URL?,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants