about summary refs log tree commit homepage
path: root/lib/upr/monitor.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/upr/monitor.rb')
-rw-r--r--lib/upr/monitor.rb9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/upr/monitor.rb b/lib/upr/monitor.rb
index 2b4732c..ec285c9 100644
--- a/lib/upr/monitor.rb
+++ b/lib/upr/monitor.rb
@@ -5,10 +5,10 @@ module Upr
   # This uses any {Moneta}[http://github.com/wycats/moneta]
   # store to monitor upload progress.
   #
-  # Usage (in config.ru with Moneta::Memory store):
+  # Usage (in config.ru with Moneta Memory store):
   #   require 'upr'
-  #   require 'moneta/memory'
-  #   use Upr, :backend => Upr::Monitor.new(Moneta::Memory.new)
+  #   require 'moneta'
+  #   use Upr, :backend => Upr::Monitor.new(Moneta.new(:Memory, :serializer => nil))
   #   run YourApplication.new
   class Monitor < Struct.new(:moneta)
     # nuke anything not read/updated in 60 seconds
@@ -17,8 +17,7 @@ module Upr
     def initialize(moneta_store = nil)
       super
       if moneta_store.nil?
-        require 'moneta/memory' # moneta does not autoload :<
-        self.moneta = Moneta::Memory.new
+        self.moneta = Moneta.new(:Memory, :serializer => nil)
       end
     end