From: Tim Otten Date: Thu, 11 Apr 2013 18:20:40 +0000 (-0300) Subject: Update permissions.php X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=d013d45c07cba03414636fec32024a4d6e446505;p=civicrm-core.git Update permissions.php Explain how replace and delete permissions relate --- diff --git a/CRM/Core/DAO/permissions.php b/CRM/Core/DAO/permissions.php index e2cf3b2631..5112e0274f 100644 --- a/CRM/Core/DAO/permissions.php +++ b/CRM/Core/DAO/permissions.php @@ -392,6 +392,10 @@ function _civicrm_api3_permissions($entity, $action, &$params) { // Translate specific actions into their generic equivalents $snippet = substr($action, 0, 3); if ($action == 'replace' || $snippet == 'del') { + // 'Replace' is a combination of get+create+update+delete; however, the permissions + // on each of those will be tested separately at runtime. This is just a sniff-test + // based on the heuristic that 'delete' tends to be the most closesly guarded + // of the necessary permissions. $action = 'delete'; } elseif ($action == 'setvalue' || $snippet == 'upd') {