Zend Framework

Zend_Service_Amazon_EditorialReview gives an error on missing element

Details

  • Type: Bug Bug
  • Status: Open Open
  • Priority: Major Major
  • Resolution: Unresolved
  • Affects Version/s: 1.7.2
  • Fix Version/s: None
  • Component/s: Zend_Service_Amazon
  • Labels:
    None

Description

When I call the ItemLookup für die ASIN "B002ACP13M" I receive an Notice as it is "Trying to get property of non-object ". On a closer look into the xml data from Amazon it delivers only an Content Tag and no Source Tag...

Activity

Hide
Mario Raspe added a comment -

I have the same problem with Zend_Service_Amazon_EditorialReview (Trying to get property of non-object...), because the xpath with "Source" isn´t find (in my case). A possible bugfix is the following code (like in Zend_Service_Amazon_CustomerReview):

$result = $xpath->query("./az:$el/text()", $dom);
if ($result->length == 1) { $this->$el = (string) $result->item(0)->data; }

I hope, i could help. (Sorry, for my bad english)

Show
Mario Raspe added a comment - I have the same problem with Zend_Service_Amazon_EditorialReview (Trying to get property of non-object...), because the xpath with "Source" isn´t find (in my case). A possible bugfix is the following code (like in Zend_Service_Amazon_CustomerReview): $result = $xpath->query("./az:$el/text()", $dom); if ($result->length == 1) { $this->$el = (string) $result->item(0)->data; } I hope, i could help. (Sorry, for my bad english)

People

Vote (1)
Watch (2)

Dates

  • Created:
    Updated: