projects
/
civicrm-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge pull request #2998 from yashodha/CRM-14500
[civicrm-core.git]
/
CRM
/
ACL
/
API.php
diff --git
a/CRM/ACL/API.php
b/CRM/ACL/API.php
index 664818a5baef85833848db9a56dd23420b406a90..8463f8b265e421d7d509a6867e0ef297c7264779 100644
(file)
--- a/
CRM/ACL/API.php
+++ b/
CRM/ACL/API.php
@@
-1,9
+1,9
@@
<?php
/*
+--------------------------------------------------------------------+
<?php
/*
+--------------------------------------------------------------------+
- | CiviCRM version 4.
4
|
+ | CiviCRM version 4.
5
|
+--------------------------------------------------------------------+
+--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-201
3
|
+ | Copyright CiviCRM LLC (c) 2004-201
4
|
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
@@
-28,7
+28,7
@@
/**
*
* @package CRM
/**
*
* @package CRM
- * @copyright CiviCRM LLC (c) 2004-201
3
+ * @copyright CiviCRM LLC (c) 2004-201
4
* $Id$
*
*/
* $Id$
*
*/
@@
-178,10
+178,17
@@
class CRM_ACL_API {
$contactID = NULL,
$tableName = 'civicrm_saved_search',
$allGroups = NULL,
$contactID = NULL,
$tableName = 'civicrm_saved_search',
$allGroups = NULL,
- $includedGroups = NULL
+ $includedGroups = NULL,
+ $flush = FALSE
) {
) {
- static $cache = array();
+ static $cache = array();
+ //@todo this is pretty hacky!!!
+ //adding a way for unit tests to flush the cache
+ if ($flush) {
+ $cache = array();
+ return;
+ }
if (!$contactID) {
$session = CRM_Core_Session::singleton();
$contactID = NULL;
if (!$contactID) {
$session = CRM_Core_Session::singleton();
$contactID = NULL;