public function __get($name) { if ($this->isValidField($name)) { if (isset($this->data[$name])) { return $this->data[$name]; } else { return null; } } else { throw new Infusionsoft_Exception("Invalid Field Name: " . $name); return ''; } }