fix style in feedparser

This commit is contained in:
Andrew Dolgov 2013-09-25 14:26:45 +04:00
parent f227d0af28
commit 4d49863f65
1 changed files with 7 additions and 7 deletions

View File

@ -42,7 +42,7 @@ class FeedParser {
// some terrible invalid unicode entity?
if ($error) {
foreach(libxml_get_errors() as $err) {
foreach (libxml_get_errors() as $err) {
if ($err->code == 9) {
// remove dangling bytes
$data = mb_convert_encoding($data, 'UTF-8', 'UTF-8');
@ -64,9 +64,9 @@ class FeedParser {
}
$this->error = "";
if($error) {
foreach(libxml_get_errors() as $error) {
if($error->level == LIBXML_ERR_FATAL) {
if ($error) {
foreach (libxml_get_errors() as $error) {
if ($error->level == LIBXML_ERR_FATAL) {
$this->error = $this->format_error($error);
break; //break here because currently we only show one error
}