title: Rails 3 library not loading until require
body: <p>I'm trying to load the Tokbox SDK in rails 3. I've placed the library in my /lib directory, so currently my directory structure looks like so:</p>
  
  <p>/lib<br />
  &nbsp;&nbsp;opentok.rb<br />
  &nbsp;&nbsp;/OpenTok<br />
  &nbsp;&nbsp;&nbsp;&nbsp;Exceptions.rb<br />
  &nbsp;&nbsp;&nbsp;&nbsp;OpenTokSDK.rb<br />
  &nbsp;&nbsp;&nbsp;&nbsp;Session.rb<br /></p>
  
  <p>I'm loading all files in the /lib directory using the following in application.rb:</p>
  
  <pre><code>config.autoload_paths += %W(#{config.root}/lib)
  config.autoload_paths += Dir["#{config.root}/lib/**/"]
  </code></pre>
  
  <p>Other files I have in the /lib directory are auto-loading just fine, but this library does not load until I add a <code>require 'OpenTok'</code>:</p>
  
  <pre><code>ruby-1.9.2-p0 &gt; OpenTok
  NameError: uninitialized constant OpenTok
  ruby-1.9.2-p0 &gt; OpenTok::OpenTokSDK
  NameError: uninitialized constant OpenTok
  ruby-1.9.2-p0 &gt; require 'OpenTok'
   =&gt; ["OpenTok"]
  ruby-1.9.2-p0 &gt; OpenTok
   =&gt; OpenTok
  ruby-1.9.2-p0 &gt; OpenTok::OpenTokSDK
   =&gt; OpenTok::OpenTokSDK 
  </code></pre>
  
  <p>What is the correct way to load the library in Rails 3?</p>