about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2011-01-05 16:15:29 -0800
committerEric Wong <normalperson@yhbt.net>2011-01-05 16:15:29 -0800
commit9b6679ec50ecd184fccd195bd14bda3c6ea2070f (patch)
treefec55e18cb3e3876525582327e9c74506e458b0e
parent950b4ba1454543de492efffdf4022f481ca7e4c2 (diff)
downloadrainbows-9b6679ec50ecd184fccd195bd14bda3c6ea2070f.tar.gz
Yes, I'm still learning Ruby.
-rw-r--r--lib/rainbows.rb9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/rainbows.rb b/lib/rainbows.rb
index 909e97e..3f9058e 100644
--- a/lib/rainbows.rb
+++ b/lib/rainbows.rb
@@ -80,14 +80,13 @@ module Rainbows
     end
 
     # :stopdoc:
-    # the default max body size is 1 megabyte (1024 * 1024 bytes)
-    @@max_bytes = 1024 * 1024
-
-    def max_bytes; @@max_bytes; end
-    def max_bytes=(nr); @@max_bytes = nr; end
+    attr_accessor :max_bytes
     # :startdoc:
   end
 
+  # the default max body size is 1 megabyte (1024 * 1024 bytes)
+  @max_bytes = 1024 * 1024
+
   # :stopdoc:
   # maps models to default worker counts, default worker count numbers are
   # pretty arbitrary and tuning them to your application and hardware is