Created
January 24, 2012 19:51
-
-
Save davidcelis/1672173 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Engine | |
mattr_accessor :user_class, :redis, :redis_host, :redis_port | |
class << self | |
def user_class | |
@@user_class.constantize | |
end | |
def redis | |
@@redis ||= Redis.new(@@redis_host, @@redis_port) | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment