diff --git a/plugins/housekeeping/gsd-disk-space.c b/plugins/housekeeping/gsd-disk-space.c
index 815012d..83f7760 100644
--- a/plugins/housekeeping/gsd-disk-space.c
+++ b/plugins/housekeeping/gsd-disk-space.c
@@ -405,7 +405,6 @@ delete_subdir (GObject      *source,
         if (error) {
                 if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_NOT_DIRECTORY))
                         g_warning ("Failed to enumerate children of %s: %s\n", data->name, error->message);
-                g_error_free (error);
         }
         if (enumerator) {
                 g_file_enumerator_next_files_async (enumerator, 20,
@@ -413,7 +412,18 @@ delete_subdir (GObject      *source,
                                                     data->cancellable,
                                                     delete_batch,
                                                     delete_data_ref (data));
+        } else if (data->depth > 0 && g_error_matches (error, G_IO_ERROR, G_IO_ERROR_NOT_DIRECTORY)) {
+                if ((data->trash && data->depth > 1) ||
+                     should_purge_file (data->file, data->cancellable, data->old)) {
+                        g_debug ("GsdHousekeeping: purging %s leaf node\n", data->name);
+                        if (!data->dry_run) {
+                                g_file_delete (data->file, data->cancellable, NULL);
+                        }
+                }
         }
+
+        if (error)
+                g_error_free (error);
         delete_data_unref (data);
 }
 
