Permalink
Browse files

fix(relationships): Invalid relationship names throw properly

  • Loading branch information...
mrclay committed Jun 21, 2015
1 parent 37425f2 commit ac976e23394f0dcba2f6b473b7f63a57082cf5d5
Showing with 2 additions and 2 deletions.
  1. +2 −2 engine/classes/Elgg/Database/RelationshipsTable.php
@@ -90,14 +90,14 @@ function delete($id) {
* @param int $guid_two GUID of the target entity of the relationship
*
* @return bool
- * @throws InvalidArgumentException
+ * @throws \InvalidArgumentException
*/
function add($guid_one, $relationship, $guid_two) {
if (strlen($relationship) > \ElggRelationship::RELATIONSHIP_LIMIT) {
$msg = "relationship name cannot be longer than " . \ElggRelationship::RELATIONSHIP_LIMIT;
- throw InvalidArgumentException($msg);
+ throw new \InvalidArgumentException($msg);
}
$guid_one = (int)$guid_one;

0 comments on commit ac976e2

Please sign in to comment.