From 78b94442747f613372b4ccd58c283fb2356608c8 Mon Sep 17 00:00:00 2001 From: Maurice Parker Date: Mon, 15 Mar 2021 20:10:42 -0500 Subject: [PATCH] Remove extra unused parameter in delegate signature --- Mac/MainWindow/Detail/DetailViewController.swift | 2 +- Mac/MainWindow/Detail/DetailWebViewController.swift | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Mac/MainWindow/Detail/DetailViewController.swift b/Mac/MainWindow/Detail/DetailViewController.swift index 63e632b21..250a04c3a 100644 --- a/Mac/MainWindow/Detail/DetailViewController.swift +++ b/Mac/MainWindow/Detail/DetailViewController.swift @@ -101,7 +101,7 @@ extension DetailViewController: DetailWebViewControllerDelegate { statusBarView.mouseoverLink = link } - func mouseDidExit(_ detailWebViewController: DetailWebViewController, link: String) { + func mouseDidExit(_ detailWebViewController: DetailWebViewController) { guard detailWebViewController === currentWebViewController else { return } diff --git a/Mac/MainWindow/Detail/DetailWebViewController.swift b/Mac/MainWindow/Detail/DetailWebViewController.swift index b661a3e86..ac89b70ba 100644 --- a/Mac/MainWindow/Detail/DetailWebViewController.swift +++ b/Mac/MainWindow/Detail/DetailWebViewController.swift @@ -14,7 +14,7 @@ import Articles protocol DetailWebViewControllerDelegate: class { func mouseDidEnter(_: DetailWebViewController, link: String) - func mouseDidExit(_: DetailWebViewController, link: String) + func mouseDidExit(_: DetailWebViewController) } final class DetailWebViewController: NSViewController, WKUIDelegate { @@ -178,8 +178,8 @@ extension DetailWebViewController: WKScriptMessageHandler { if message.name == MessageName.mouseDidEnter, let link = message.body as? String { delegate?.mouseDidEnter(self, link: link) } - else if message.name == MessageName.mouseDidExit, let link = message.body as? String{ - delegate?.mouseDidExit(self, link: link) + else if message.name == MessageName.mouseDidExit { + delegate?.mouseDidExit(self) } } }