private static function parseErrorNode($node) { $error = new Recurly_FieldError(); $error->field = $node->getAttribute('field'); $error->symbol = $node->getAttribute('symbol'); $error->description = $node->firstChild->wholeText; return $error; }