Skip to content
Browse files

Swap to exceptions

  • Loading branch information...
1 parent 69a8af2 commit e074214a432afae1650556a7006c250c93c030dc @CloCkWeRX CloCkWeRX committed Mar 25, 2012
Showing with 5 additions and 2 deletions.
  1. +5 −2 RDF/Serializer.php
View
7 RDF/Serializer.php
@@ -2,6 +2,9 @@
// ----------------------------------------------------------------------------------
// Class: RDF_Serializer
// ----------------------------------------------------------------------------------
+
+require_once 'RDF/Exception.php';
+
/**
* An RDF seralizer.
* Seralizes models to RDF syntax. It supports the xml:base, xml:lang, rdf:datatype and
@@ -694,7 +697,7 @@ function getElementText($elementName)
if ($prefix === false) {
$errmsg = "Prefix for element '$elementName' cannot be found.";
- return RDF::raiseError(RDF_ERROR, null, null, $errmsg);
+ throw new RDF_Exception($errmsg, RDF_ERROR);
}
if ($prefix != RDF_NAMESPACE_PREFIX) {
return $prefix . ':' . $localName;
@@ -761,4 +764,4 @@ function getNextNamespacePrefix()
}
}
-?>
+?>

0 comments on commit e074214

Please sign in to comment.
Something went wrong with that request. Please try again.