original_string: public function addDatabaseReaderRole($role)
  	{
  		if (strlen($role) < 1) {
  			throw new InvalidArgumentException("Role can't be empty");
  		}
  		$sec = $this->getSecurity();
  		if (in_array($role, $sec->readers->roles)) {
  			return true;
  		}
  		array_push($sec->readers->roles, $role);
  		$back = $this->setSecurity($sec);
  		if (is_object($back) && property_exists($back, "ok") && $back->ok == true) {
  			return true;
  		}
  		return false;
  	}
code: public function addDatabaseReaderRole($role)
  	{
  		if (strlen($role) < 1) {
  			throw new InvalidArgumentException("Role can't be empty");
  		}
  		$sec = $this->getSecurity();
  		if (in_array($role, $sec->readers->roles)) {
  			return true;
  		}
  		array_push($sec->readers->roles, $role);
  		$back = $this->setSecurity($sec);
  		if (is_object($back) && property_exists($back, "ok") && $back->ok == true) {
  			return true;
  		}
  		return false;
  	}
code_tokens: public function addDatabaseReaderRole ( $ role ) { if ( strlen ( $ role ) < 1 ) { throw new InvalidArgumentException ( "Role can't be empty" ) ; } $ sec = $ this -> getSecurity ( ) ; if ( in_array ( $ role , $ sec -> readers -> roles ) ) { return true ; } array_push ( $ sec -> readers -> roles , $ role ) ; $ back = $ this -> setSecurity ( $ sec ) ; if ( is_object ( $ back ) && property_exists ( $ back , "ok" ) && $ back -> ok == true ) { return true ; } return false ; }
docstring: add a role to the list of readers for the current database
  
  @param string $role role name
  @return boolean true if the role has successfuly been added
  @throws InvalidArgumentException
docstring_tokens: add a role to the list of readers for the current database