summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsun2008-09-05 20:09:32 (GMT)
committer sun2008-09-05 20:09:32 (GMT)
commita5cbe140f38a725e450a77ded0d0679bf9e3fa5c (patch)
treea218ed89b6d0163d2df930d06568f710b250f10f
parenta4cf28f1ccfa8f7bf1b047c7a503546ef56d4c1e (diff)
#304243 by sun: Code clean-up for wysiwyg_editor_user_status().
-rw-r--r--CHANGELOG.txt1
-rw-r--r--wysiwyg_editor.module4
2 files changed, 3 insertions, 2 deletions
diff --git a/CHANGELOG.txt b/CHANGELOG.txt
index 97f770c..e94bc1a 100644
--- a/CHANGELOG.txt
+++ b/CHANGELOG.txt
@@ -6,6 +6,7 @@ Wysiwyg x.x-x.x, xxxx-xx-xx
Wysiwyg 5.x-x.x, xxxx-xx-xx
---------------------------
+#304243 by sun: Code clean-up for wysiwyg_editor_user_status().
#299108 by toniw: Added setting for TinyMCE's auto-cleanup paste feature.
#293916 by sun: Clarified TinyMCE compatibility in README.txt.
#293425 by sun: Fixed foreach warning during upgrade from TinyMCE module.
diff --git a/wysiwyg_editor.module b/wysiwyg_editor.module
index 8126748..30f866f 100644
--- a/wysiwyg_editor.module
+++ b/wysiwyg_editor.module
@@ -591,8 +591,8 @@ function wysiwyg_editor_user_get_profile($account) {
function wysiwyg_editor_user_get_status($user, $profile) {
$settings = $profile->settings;
- if ($settings['user_choose']) {
- $status = isset($user->wysiwyg_editor_status) ? $user->wysiwyg_editor_status : (isset($settings['default']) ? $settings['default'] : FALSE);
+ if ($settings['user_choose'] && isset($user->wysiwyg_editor_status)) {
+ $status = $user->wysiwyg_editor_status;
}
else {
$status = isset($settings['default']) ? $settings['default'] : FALSE;