summaryrefslogtreecommitdiff
path: root/Remote.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2015-01-16 13:29:54 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2015-01-16 13:29:54 -0400
commit693d324e2b3e7af786a17f251fa8075593064883 (patch)
tree97d44100173c97d243e137f3289cc0af8b752c83 /Remote.hs
parent760f8ab86c916f884ee4666ab7203caa8f5ec686 (diff)
Fix wording of message displayed when unable to get a file that is available in untrusted repositories.
Diffstat (limited to 'Remote.hs')
-rw-r--r--Remote.hs8
1 files changed, 5 insertions, 3 deletions
diff --git a/Remote.hs b/Remote.hs
index 24923337b..a48c5f75e 100644
--- a/Remote.hs
+++ b/Remote.hs
@@ -272,11 +272,13 @@ keyPossibilities' key trusted = do
return (sortBy (comparing cost) validremotes, validtrusteduuids)
{- Displays known locations of a key. -}
-showLocations :: Key -> [UUID] -> String -> Annex ()
-showLocations key exclude nolocmsg = do
+showLocations :: Bool -> Key -> [UUID] -> String -> Annex ()
+showLocations separateuntrusted key exclude nolocmsg = do
u <- getUUID
uuids <- keyLocations key
- untrusteduuids <- trustGet UnTrusted
+ untrusteduuids <- if separateuntrusted
+ then trustGet UnTrusted
+ else pure []
let uuidswanted = filteruuids uuids (u:exclude++untrusteduuids)
let uuidsskipped = filteruuids uuids (u:exclude++uuidswanted)
ppuuidswanted <- prettyPrintUUIDs "wanted" uuidswanted