From 59887560ed20d0ec96843b96dc44593f6108712c Mon Sep 17 00:00:00 2001 From: Fabio Rehm Date: Tue, 11 Feb 2014 23:24:48 -0200 Subject: [PATCH] Trigger plugin activation by setting cache scope [GH-17] --- lib/vagrant-cachier/config.rb | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/vagrant-cachier/config.rb b/lib/vagrant-cachier/config.rb index fb43280..5d2351c 100644 --- a/lib/vagrant-cachier/config.rb +++ b/lib/vagrant-cachier/config.rb @@ -46,7 +46,7 @@ module VagrantPlugins def enabled? return @enabled unless @enabled.nil? - @enabled = (@auto_detect != UNSET_VALUE || @buckets != nil) + @enabled = @scope != UNSET_VALUE end def disable! @@ -56,8 +56,7 @@ module VagrantPlugins def finalize! return unless enabled? - @scope = :box if @scope == UNSET_VALUE - @auto_detect = false if @auto_detect == UNSET_VALUE + @auto_detect = true if @auto_detect == UNSET_VALUE @synced_folder_opts = nil if @synced_folder_opts == UNSET_VALUE @buckets = @buckets ? @buckets.dup : {} end