From 965cbe52f22809f19ca150feb585b0218aa89f85 Mon Sep 17 00:00:00 2001 From: brettp Date: Wed, 22 Sep 2010 17:01:17 +0000 Subject: Converted line endings to unix. git-svn-id: http://code.elgg.org/elgg/trunk@6957 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/classes/AccessControlQueryComponent.php | 76 +++++++++++++------------- 1 file changed, 38 insertions(+), 38 deletions(-) (limited to 'engine/classes/AccessControlQueryComponent.php') diff --git a/engine/classes/AccessControlQueryComponent.php b/engine/classes/AccessControlQueryComponent.php index 7808800bc..07028462f 100644 --- a/engine/classes/AccessControlQueryComponent.php +++ b/engine/classes/AccessControlQueryComponent.php @@ -1,39 +1,39 @@ -acl_table = $CONFIG->dbprefix . sanitise_string($acl_table); - $this->acl_field = sanitise_string($acl_field); - $this->object_owner_table = $CONFIG->dbprefix . sanitise_string($object_owner_table); - $this->object_owner_id_field = sanitise_string($object_owner_id_field); - } - - function __toString() { - //$access = get_access_list(); - // KJ - changed to use get_access_sql_suffix - // Note: currently get_access_sql_suffix is hardwired to use - // $acl_field = "access_id", $object_owner_table = $acl_table, and - // $object_owner_id_field = "owner_guid" - // @todo recode get_access_sql_suffix to make it possible to specify alternate field names - return "and ".get_access_sql_suffix($this->acl_table); // Add access controls - - //return "and ({$this->acl_table}.{$this->acl_field} in {$access} or ({$this->acl_table}.{$this->acl_field} = 0 and {$this->object_owner_table}.{$this->object_owner_id_field} = {$_SESSION['id']}))"; - } +acl_table = $CONFIG->dbprefix . sanitise_string($acl_table); + $this->acl_field = sanitise_string($acl_field); + $this->object_owner_table = $CONFIG->dbprefix . sanitise_string($object_owner_table); + $this->object_owner_id_field = sanitise_string($object_owner_id_field); + } + + function __toString() { + //$access = get_access_list(); + // KJ - changed to use get_access_sql_suffix + // Note: currently get_access_sql_suffix is hardwired to use + // $acl_field = "access_id", $object_owner_table = $acl_table, and + // $object_owner_id_field = "owner_guid" + // @todo recode get_access_sql_suffix to make it possible to specify alternate field names + return "and ".get_access_sql_suffix($this->acl_table); // Add access controls + + //return "and ({$this->acl_table}.{$this->acl_field} in {$access} or ({$this->acl_table}.{$this->acl_field} = 0 and {$this->object_owner_table}.{$this->object_owner_id_field} = {$_SESSION['id']}))"; + } } \ No newline at end of file -- cgit v1.2.3