| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* Temporarily change a global variable.
* We don't have a container or dependency-injection, so use singleton instead
*
* @var object
- * @static
*/
private static $_singleton = NULL;
}
/**
- * @param array $new the new, incoming frame
- * @return array frame
+ * @param array $new
+ * The new, incoming frame.
+ * @return array
+ * frame
*/
public function createBackup($new) {
$frame = array();
foreach ($values as $key => $value) {
$frame[$globalKey][$key] = CRM_Utils_Array::value($key, $GLOBALS[$globalKey]);
}
- } else {
+ }
+ else {
$frame[$globalKey] = CRM_Utils_Array::value($globalKey, $GLOBALS);
}
}
foreach ($values as $key => $value) {
$GLOBALS[$globalKey][$key] = $value;
}
- } else {
+ }
+ else {
$GLOBALS[$globalKey] = $values;
}
}
}
+
}