$this->company_id = $c->id;
$this->email = trim($this->email);
+ $pp = DB_DataObject::factory('core_person');
+ $pp->email = $this->email;
+ if ($pp->count()){
+ $roo->jerr("that email already exists in the database");
+ }
+
+
+
+
}
function onInsert($req, $roo)