Beispiel #1
0
 /**
  * Parse the data
  * @param array $data shall be the response body
  * @param string $type data type
  */
 public function process(array $data, $type, $parentId = null)
 {
     try {
         $this->parser->process($data, $type, $parentId);
     } catch (NoDataException $e) {
         Logger::log('debug', "No data returned in '{$type}'");
     } catch (JsonParserException $e) {
         throw new UserException("Error parsing response JSON: " . $e->getMessage(), 500, $e, $e->getData());
     }
 }