From 9f393e1c57cae100f1c137e2b4201c92b257d983 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Wed, 6 Dec 2017 10:54:48 -0400 Subject: avoid build warning when built w/o dbus --- Annex/Notification.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Annex/Notification.hs b/Annex/Notification.hs index f3d5006e3..27acd0302 100644 --- a/Annex/Notification.hs +++ b/Annex/Notification.hs @@ -40,10 +40,10 @@ instance Transferrable URLString where - attempts. Displays notification when supported and when the user asked - for it. -} notifyTransfer :: Transferrable t => Observable v => Direction -> t -> (NotifyWitness -> Annex v) -> Annex v +#ifdef WITH_DBUS_NOTIFICATIONS notifyTransfer direction t a = case descTransfrerrable t of Nothing -> a NotifyWitness Just desc -> do -#ifdef WITH_DBUS_NOTIFICATIONS wanted <- Annex.getState Annex.desktopnotify if (notifyStart wanted || notifyFinish wanted) then do @@ -60,7 +60,7 @@ notifyTransfer direction t a = case descTransfrerrable t of return res else a NotifyWitness #else - a NotifyWitness +notifyTransfer _ _ a = a NotifyWitness #endif notifyDrop :: AssociatedFile -> Bool -> Annex () -- cgit v1.2.3