summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEarl Miles2008-09-16 22:46:42 (GMT)
committerEarl Miles2008-09-16 22:46:42 (GMT)
commit6d9dbdfe81f8ab1d8b30f83dd2516f523d559ef0 (patch)
treeb93dfd3f82534013eee42d5853ea0137b46c1942
parent777574630ba22bab5dca02c9e31c1be33d70528f (diff)
#307013: Fix translated nodes not appearing.
-rw-r--r--panels_node_content/panels_node_content.module7
1 files changed, 5 insertions, 2 deletions
diff --git a/panels_node_content/panels_node_content.module b/panels_node_content/panels_node_content.module
index d51de39..42216e9 100644
--- a/panels_node_content/panels_node_content.module
+++ b/panels_node_content/panels_node_content.module
@@ -73,8 +73,11 @@ function panels_node_content_render($subtype, $conf, $panel_args) {
// Support node translation
if (module_exists('translation')) {
- if ($translation = module_invoke('translation', 'node_nid', $nid, $GLOBALS['locale'])) {
- $nid = $translation;
+ if ($translations = module_invoke('translation', 'node_get_translations', $nid )) {
+ if( $translations[$GLOBALS['language']->language] )
+ {
+ $nid = $translations[$GLOBALS['language']->language]->nid;
+ }
}
}