summaryrefslogtreecommitdiff
path: root/guix/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'guix/scripts')
-rw-r--r--guix/scripts/locate.scm2
1 files changed, 1 insertions, 1 deletions
diff --git a/guix/scripts/locate.scm b/guix/scripts/locate.scm
index ae64f46896..92af3509bf 100644
--- a/guix/scripts/locate.scm
+++ b/guix/scripts/locate.scm
@@ -657,7 +657,7 @@ Locate FILE and return the list of packages that contain it.\n"))
files)))
(()
(if (null? files)
- (unless update?
+ (unless (or update? (assoc-ref opts 'clear?))
(leave (G_ "no files to search for~%")))
(leave (N_ "file~{ '~a'~} not found in database '~a'~%"
"files~{ '~a'~} not found in database '~a'~%"