Issue #2763283 by naught101, thomas73: Failure on comments with no subject

8.3.x
Alex Pott 2016-08-13 23:52:22 +01:00
parent 0c0481ef86
commit 24343f970b
2 changed files with 3 additions and 3 deletions

View File

@ -20,7 +20,7 @@ class CommentVariablePerCommentType extends CommentVariable {
$return = array();
foreach ($node_types as $node_type => $data) {
// Only 2 comment types depending on subject field visibility.
if (empty($data['comment_subject_field'])) {
if (!empty($data['comment_subject_field'])) {
// Default label and description should be set in migration.
$return['comment'] = array(
'comment_type' => 'comment',

View File

@ -24,10 +24,10 @@ class CommentVariablePerCommentTypeTest extends MigrateSqlSourceTestCase {
// Each result will also include a label and description, but those are
// static values set by the source plugin and don't need to be asserted.
array(
'comment_type' => 'comment_no_subject',
'comment_type' => 'comment',
),
array(
'comment_type' => 'comment',
'comment_type' => 'comment_no_subject',
),
);