From f0d77a23a406fc1a04d82c356799bb1df93159ec Mon Sep 17 00:00:00 2001 From: Matthias H Date: Mon, 24 Feb 2014 06:11:16 +0100 Subject: [PATCH] [registry] optimize at every restart/rescan --- lib/rbot/registry.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/rbot/registry.rb b/lib/rbot/registry.rb index 6c18df21..799e69ee 100644 --- a/lib/rbot/registry.rb +++ b/lib/rbot/registry.rb @@ -73,7 +73,9 @@ class Registry # (the configured one) accessor implementation, we can just assume # it to be the correct accessor to use. cls = AbstractAccessor.get_impl.first - cls.new(File.join(path, 'registry_' + @format, filename.downcase)) + db = cls.new(File.join(path, 'registry_' + @format, filename.downcase)) + db.optimize + db end # Helper method that will return a list of supported registry formats. -- 2.39.5