title: How to get items from a Ruby hash?
body: <p>I have the following hash being returned from the Google Drive API:</p>
  
  <pre><code>@export_links=
   {"application/rtf"=&gt;
     "https://docs.google.com/feeds/download/documents/export/Export?id=xxx&amp;exportFormat=rtf",
    "application/vnd.oasis.opendocument.text"=&gt;
     "https://docs.google.com/feeds/download/documents/export/Export?id=xxx&amp;exportFormat=odt",
    "text/html"=&gt;
     "https://docs.google.com/feeds/download/documents/export/Export?id=xxx&amp;exportFormat=html",
    "application/pdf"=&gt;
     "https://docs.google.com/feeds/download/documents/export/Export?id=xxx&amp;exportFormat=pdf",
    "application/zip"=&gt;
     "https://docs.google.com/feeds/download/documents/export/Export?id=xxx&amp;exportFormat=zip",
    "application/vnd.openxmlformats-officedocument.wordprocessingml.document"=&gt;
     "https://docs.google.com/feeds/download/documents/export/Export?id=xxxx&amp;exportFormat=docx",
    "text/plain"=&gt;
     "https://docs.google.com/feeds/download/documents/export/Export?id=xxx&amp;exportFormat=txt"},
  </code></pre>
  
  <p>I'm able to log export links like so:</p>
  
  <pre><code>logger.debug  file.export_links
  </code></pre>
  
  <p>However, I'm unable to get the text/plain url, trying:</p>
  
  <pre><code>logger.debug  file.export_links["text/plain"]
  </code></pre>
  
  <p>This is erroring with <code>undefined method</code>[]' for nil:NilClass`.</p>
  
  <p>How can I get the value for text/plain within @export_links? </p>