CRM-13141 restructured code to handle empty 200 result from public extensions directory.

----------------------------------------
* CRM-13141: Manage Extensions throws an erroneous fatal error - Failed Fetching List - when there are no extensions available for a particular install version
  http://issues.civicrm.org/jira/browse/CRM-13141
Corrected issue in patch noted by Tim on PR.
Merge pull request #1298 from davecivicrm/CRM-13141

CRM-13141 restructured code to handle empty 200 result from public exten...