change removeExport to throw exception

Part of ongoing transition to make remote methods
throw exceptions, rather than silently hide them.

This commit was sponsored by Graham Spencer on Patreon.
This commit is contained in:
Joey Hess 2020-05-15 14:11:59 -04:00
parent 3334d3831b
commit cdbfaae706
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
11 changed files with 70 additions and 59 deletions

View file

@ -325,9 +325,9 @@ checkPresentExportM o _k loc = checkPresentGeneric o [rsyncurl]
where
rsyncurl = mkRsyncUrl o (fromRawFilePath (fromExportLocation loc))
removeExportM :: RsyncOpts -> Key -> ExportLocation -> Annex Bool
removeExportM :: RsyncOpts -> Key -> ExportLocation -> Annex ()
removeExportM o _k loc =
removeGeneric' o $ includes $ fromRawFilePath $ fromExportLocation loc
removeGeneric o $ includes $ fromRawFilePath $ fromExportLocation loc
where
includes f = f : case upFrom f of
Nothing -> []