Update of /cvsroot/php-blog/serendipity/include
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7724/include
Modified Files:
functions_entries.inc.php
Log Message:
Fix a bug that when you set your "draft default" state in personal preferences
it affected when editing an entry to be always set to "draft" instead of the real state.
Thus the if-condition now properly checks whether the isdraft flag is not yet set
and only apply the default setting then.
Index: functions_entries.inc.php
===================================================================
RCS file: /cvsroot/php-blog/serendipity/include/functions_entries.inc.php,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -d -r1.57 -r1.58
--- functions_entries.inc.php 18 Feb 2005 16:13:42 -0000 1.57
+++ functions_entries.inc.php 18 Feb 2005 19:48:10 -0000 1.58
@@ -1117,7 +1117,8 @@
serendipity_plugin_api::hook_event('backend_entryform', $entry);
- if (isset($entry['isdraft']) && $entry['isdraft'] == 'true' || $serendipity['publishDefault'] == 'draft') {
+ if ( (isset($entry['isdraft']) && $entry['isdraft'] == 'true') ||
+ (!isset($entry['isdraft']) && $serendipity['publishDefault'] == 'draft') ) {
$draftD = ' selected="selected"';
} else {
$draftP = ' selected="selected"';
|