summaryrefslogtreecommitdiff
path: root/modules/forum
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2009-12-02 19:26:23 +0000
committerDries Buytaert <dries@buytaert.net>2009-12-02 19:26:23 +0000
commit0baad49d620d9988837287cb5942eea764d3ed6f (patch)
tree146072f69b433cb7922572ba2ac627a83987edd4 /modules/forum
parentef4513651e210784ba84eb310cf919e26f668bed (diff)
downloadbrdo-0baad49d620d9988837287cb5942eea764d3ed6f.tar.gz
brdo-0baad49d620d9988837287cb5942eea764d3ed6f.tar.bz2
- Patch #635094 by plach: unify 'language neutral' language codes.
Diffstat (limited to 'modules/forum')
-rw-r--r--modules/forum/forum.module4
-rw-r--r--modules/forum/forum.test8
2 files changed, 6 insertions, 6 deletions
diff --git a/modules/forum/forum.module b/modules/forum/forum.module
index e1c45700a..8aa51713a 100644
--- a/modules/forum/forum.module
+++ b/modules/forum/forum.module
@@ -431,7 +431,7 @@ function forum_field_storage_pre_insert($obj_type, $object, &$skip_fields) {
foreach ($language as $item) {
$query->values(array(
'nid' => $object->nid,
- 'title' => $object->title[FIELD_LANGUAGE_NONE][0]['value'],
+ 'title' => $object->title[LANGUAGE_NONE][0]['value'],
'tid' => $item['tid'],
'sticky' => $object->sticky,
'created' => $object->created,
@@ -465,7 +465,7 @@ function forum_field_storage_pre_update($obj_type, $object, &$skip_fields) {
foreach ($language as $item) {
$query->values(array(
'nid' => $object->nid,
- 'title' => $object->title[FIELD_LANGUAGE_NONE][0]['value'],
+ 'title' => $object->title[LANGUAGE_NONE][0]['value'],
'tid' => $item['tid'],
'sticky' => $object->sticky,
'created' => $object->created,
diff --git a/modules/forum/forum.test b/modules/forum/forum.test
index eadfaaa77..ae900307b 100644
--- a/modules/forum/forum.test
+++ b/modules/forum/forum.test
@@ -263,7 +263,7 @@ class ForumTestCase extends DrupalWebTestCase {
// select items list.
$tid = $forum['tid'];
- $langcode = FIELD_LANGUAGE_NONE;
+ $langcode = LANGUAGE_NONE;
$edit = array(
"title[$langcode][0][value]" => $title,
"body[$langcode][0][value]" => $body,
@@ -340,20 +340,20 @@ class ForumTestCase extends DrupalWebTestCase {
// View forum node.
$this->drupalGet('node/' . $node->nid);
$this->assertResponse(200);
- $this->assertTitle($node->title[FIELD_LANGUAGE_NONE][0]['value'] . ' | Drupal', t('Forum node was displayed'));
+ $this->assertTitle($node->title[LANGUAGE_NONE][0]['value'] . ' | Drupal', t('Forum node was displayed'));
$this->assertText(t('Home ' . $crumb . ' Forums ' . $crumb . ' @container ' . $crumb . ' @forum', array('@container' => $this->container['name'], '@forum' => $this->forum['name'])), t('Breadcrumbs were displayed'));
// View forum edit node.
$this->drupalGet('node/' . $node->nid . '/edit');
$this->assertResponse($response);
if ($response == 200) {
- $this->assertTitle('Edit Forum topic ' . $node->title[FIELD_LANGUAGE_NONE][0]['value'] . ' | Drupal', t('Forum edit node was displayed'));
+ $this->assertTitle('Edit Forum topic ' . $node->title[LANGUAGE_NONE][0]['value'] . ' | Drupal', t('Forum edit node was displayed'));
}
if ($response == 200) {
// Edit forum node (including moving it to another forum).
$edit = array();
- $langcode = FIELD_LANGUAGE_NONE;
+ $langcode = LANGUAGE_NONE;
$edit["title[$langcode][0][value]"] = 'node/' . $node->nid;
$edit["body[$langcode][0][value]"] = $this->randomName(256);
// Assume the topic is initially associated with $forum.