<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,3 +1,7 @@
+== 0.1.1 2009-01-24
+* Bugfix:
+  * #cached_xml_response was being called twice if there was a cached response
+
 == 0.1.0 2008-05-12
 * 1 major enhancement:
   * Converted to gem from Rails plugin</diff>
      <filename>History.txt</filename>
    </modified>
    <modified>
      <diff>@@ -113,7 +113,8 @@ module EbayShopping
     # the DB or file system) by calling #cached_response before making the call, and passing the response to #cache_response after making it.
     def call(url)
       check_error_cache
-      return cached_xml_response if cached_xml_response
+      cached_response = cached_xml_response
+      return cached_response if cached_response
       fresh_response = _http_get(url)
       cache_response(fresh_response)
       fresh_response</diff>
      <filename>lib/ebay_shopping.rb</filename>
    </modified>
    <modified>
      <diff>@@ -101,6 +101,15 @@ class TestEbayShopping &lt; Test::Unit::TestCase
     request.send(:call, &quot;http://some.url&quot;)
   end
   
+  def test_should_return_cached_response_if_it_exists
+    cached_response = stub
+    request = new_ebay_request
+    request.expects(:cached_xml_response).returns(cached_response)
+    request.expects(:_http_get).never
+    
+    assert_equal cached_response, request.send(:call, &quot;http://some.url&quot;)
+  end
+  
   def test_should_check_error_cache_when_call_is_made
     request = new_ebay_request
     request.stubs(:_http_get).returns(@find_items_response)</diff>
      <filename>test/test_ebay_shopping.rb</filename>
    </modified>
    <modified>
      <diff>@@ -2,7 +2,6 @@ h1. ebay_shopping
 
 h1. &amp;#x2192; 'ebay_shopping'
 
-
 h2. What
 
 A Ruby library for the fast-and-simple ebay Shopping API. For details see the Introduction, or the README file. There's also a blog post detailing usage at: &quot;http://pushrod.wordpress.com/2008/01/13/a-rubyonrails-library-for-the-ebay-shopping-api/&quot;:http://pushrod.wordpress.com/2008/01/13/a-rubyonrails-library-for-the-ebay-shopping-api/</diff>
      <filename>website/index.txt</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>8ec1f9c3242f85033efaf5efa62c0ac79a7883cc</id>
    </parent>
  </parents>
  <author>
    <name>Chris Taggart</name>
    <email>chris@windowsxponmac.home</email>
  </author>
  <url>http://github.com/ctagg/ebay_shopping/commit/d96e1da20902c19a0af0cd69ac7617e074f849e4</url>
  <id>d96e1da20902c19a0af0cd69ac7617e074f849e4</id>
  <committed-date>2009-01-24T05:34:30-08:00</committed-date>
  <authored-date>2009-01-24T05:34:30-08:00</authored-date>
  <message>Bugfix: #cached_xml_response was being called twice if there was a cached response</message>
  <tree>7b28ef509094270cf11cf3c5e61e3af81da4bf34</tree>
  <committer>
    <name>Chris Taggart</name>
    <email>chris@windowsxponmac.home</email>
  </committer>
</commit>
