aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/ucp/ucp_prefs.php
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/includes/ucp/ucp_prefs.php')
-rw-r--r--phpBB/includes/ucp/ucp_prefs.php9
1 files changed, 8 insertions, 1 deletions
diff --git a/phpBB/includes/ucp/ucp_prefs.php b/phpBB/includes/ucp/ucp_prefs.php
index 11f2d231fe..0c9f20f266 100644
--- a/phpBB/includes/ucp/ucp_prefs.php
+++ b/phpBB/includes/ucp/ucp_prefs.php
@@ -60,7 +60,14 @@ class ucp_prefs
if ($submit)
{
- $data['style'] = ($config['override_user_style']) ? $config['default_style'] : $data['style'];
+ if ($config['override_user_style'])
+ {
+ $data['style'] = (int) $config['default_style'];
+ }
+ else if (!phpbb_style_is_active($data['style']))
+ {
+ $data['style'] = (int) $user->data['user_style'];
+ }
$error = validate_data($data, array(
'dateformat' => array('string', false, 1, 30),