summaryrefslogtreecommitdiff
path: root/modules/system
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2010-04-11 18:33:44 +0000
committerDries Buytaert <dries@buytaert.net>2010-04-11 18:33:44 +0000
commitff301288f2ea06d76606c05bccac5957e2873a94 (patch)
treeb46d9d7e56612945850281a136161967ba8bc5f2 /modules/system
parentde33f74b4040cc3f7880269152b277d90b081cc8 (diff)
downloadbrdo-ff301288f2ea06d76606c05bccac5957e2873a94.tar.gz
brdo-ff301288f2ea06d76606c05bccac5957e2873a94.tar.bz2
- Patch #348448 by mfb, c960657, marvil07, cdale, jpmckinney: fixed PHP strict warnings when running tests and for PHP 5.3.
Diffstat (limited to 'modules/system')
-rw-r--r--modules/system/system.admin.inc9
-rw-r--r--modules/system/system.test1
2 files changed, 6 insertions, 4 deletions
diff --git a/modules/system/system.admin.inc b/modules/system/system.admin.inc
index e2b79a9e0..3ca45af48 100644
--- a/modules/system/system.admin.inc
+++ b/modules/system/system.admin.inc
@@ -369,7 +369,7 @@ function system_theme_enable() {
if (isset($_REQUEST['theme']) && isset($_REQUEST['token']) && drupal_valid_token($_REQUEST['token'], 'system-theme-operation-link')) {
$theme = $_REQUEST['theme'];
// Get current list of themes.
- $themes =& _system_theme_list();
+ $themes = _system_theme_list();
// Check if the specified theme is one recognized by the system.
if (!empty($themes[$theme])) {
@@ -391,7 +391,7 @@ function system_theme_disable() {
if (isset($_REQUEST['theme']) && isset($_REQUEST['token']) && drupal_valid_token($_REQUEST['token'], 'system-theme-operation-link')) {
$theme = $_REQUEST['theme'];
// Get current list of themes.
- $themes =& _system_theme_list();
+ $themes = _system_theme_list();
// Check if the specified theme is one recognized by the system.
if (!empty($themes[$theme])) {
@@ -419,7 +419,7 @@ function system_theme_default() {
if (isset($_REQUEST['theme']) && isset($_REQUEST['token']) && drupal_valid_token($_REQUEST['token'], 'system-theme-operation-link')) {
$theme = $_REQUEST['theme'];
// Get current list of themes.
- $themes =& _system_theme_list();
+ $themes = _system_theme_list();
// Check if the specified theme is one recognized by the system.
if (!empty($themes[$theme])) {
@@ -1947,7 +1947,8 @@ function system_date_time_settings() {
foreach ($formats as $f => $format) {
$choices[$f] = format_date(REQUEST_TIME, 'custom', $f);
}
- $default = variable_get('date_format_' . $type, array_shift(array_keys($formats)));
+ reset($formats);
+ $default = variable_get('date_format_' . $type, key($formats));
// Get date type info for this date type.
$type_info = system_get_date_types($type);
diff --git a/modules/system/system.test b/modules/system/system.test
index dd7b44699..6fb15a736 100644
--- a/modules/system/system.test
+++ b/modules/system/system.test
@@ -1743,6 +1743,7 @@ class CompactModeTest extends DrupalWebTestCase {
}
function setUp() {
+ parent::setUp();
$admin_user = $this->drupalCreateUser(array('access administration pages'));
$this->drupalLogin($admin_user);
}