diff --git a/NBus/Classes/Handler/WeiboHandler.swift b/NBus/Classes/Handler/WeiboHandler.swift index 13639a6..4937484 100644 --- a/NBus/Classes/Handler/WeiboHandler.swift +++ b/NBus/Classes/Handler/WeiboHandler.swift @@ -313,6 +313,25 @@ extension WeiboHandler { } } +extension WeiboHandler: OpenURLHandlerType { + + public func openURL(_ url: URL) { + guard + let components = URLComponents(url: url, resolvingAgainstBaseURL: false) + else { + assertionFailure() + return + } + + switch components.host { + case "response" where components.path == "": + handleGeneral() + default: + assertionFailure() + } + } +} + extension WeiboHandler: OpenUserActivityHandlerType { public func openUserActivity(_ userActivity: NSUserActivity) {