#56488, use named constants for comment status, patch, by Moshe
parent
2347d3f93c
commit
0f4d2e64c2
|
@ -638,13 +638,13 @@ function _blogapi_mt_extra(&$node, $struct) {
|
|||
if (array_key_exists('mt_allow_comments', $struct)) {
|
||||
switch ($struct['mt_allow_comments']) {
|
||||
case 0:
|
||||
$node->comment = 0;
|
||||
$node->comment = COMMENT_NODE_DISABLED;
|
||||
break;
|
||||
case 1:
|
||||
$node->comment = 2;
|
||||
$node->comment = COMMENT_NODE_READ_WRITE;
|
||||
break;
|
||||
case 2:
|
||||
$node->comment = 1;
|
||||
$node->comment = COMMENT_NODE_READ_ONLY;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -638,13 +638,13 @@ function _blogapi_mt_extra(&$node, $struct) {
|
|||
if (array_key_exists('mt_allow_comments', $struct)) {
|
||||
switch ($struct['mt_allow_comments']) {
|
||||
case 0:
|
||||
$node->comment = 0;
|
||||
$node->comment = COMMENT_NODE_DISABLED;
|
||||
break;
|
||||
case 1:
|
||||
$node->comment = 2;
|
||||
$node->comment = COMMENT_NODE_READ_WRITE;
|
||||
break;
|
||||
case 2:
|
||||
$node->comment = 1;
|
||||
$node->comment = COMMENT_NODE_READ_ONLY;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue