diff -ru activitystream//activitystream_delicious/activitystream_delicious.module activitystream_fr//activitystream_delicious/activitystream_delicious.module --- activitystream//activitystream_delicious/activitystream_delicious.module 2008-08-16 10:51:43.000000000 +0200 +++ activitystream_fr//activitystream_delicious/activitystream_delicious.module 2009-06-29 17:16:05.000000000 +0200 @@ -63,7 +63,7 @@ $date = theme('activitystream_date', $node->created); $user = activitystream_user_load($node->uid); $name = theme('activitystream_username', $user); - return ''. theme('activitystream_delicious_icon') ." $name linked to ". l($node->title, $action->link) ." $date". l('#', 'node/'. $node->nid, array('attributes' => array('class' => 'permalink'))) .''; + return '' . theme('activitystream_delicious_icon') . " $name " . t('linked to'). " " . l($node->title, $action->link) . " $date" . l('#', 'node/' . $node->nid, array('attributes' => array('class' => 'permalink'))) . ''; } function activitystream_delicious_theme() { @@ -75,4 +75,4 @@ 'arguments' => array('action' => NULL), ), ); -} \ No newline at end of file +} diff -ru activitystream//activitystream_digg/activitystream_digg.module activitystream_fr//activitystream_digg/activitystream_digg.module --- activitystream//activitystream_digg/activitystream_digg.module 2008-08-16 10:51:43.000000000 +0200 +++ activitystream_fr//activitystream_digg/activitystream_digg.module 2009-06-29 21:25:06.000000000 +0200 @@ -62,7 +62,7 @@ $date = theme('activitystream_date', $node->created); $user = activitystream_user_load($node->uid); $name = theme('activitystream_username', $user); - return ''. theme('activitystream_digg_icon') ." $name dugg ". l($node->title, $activity->link) ." $date". l('#', 'node/'. $node->nid, array('class' => 'permalink')) .''; + return ''. theme('activitystream_digg_icon') ." $name " . t('dugg') . " " . l($node->title, $activity->link) ." $date". l('#', 'node/'. $node->nid, array('class' => 'permalink')) .''; } function activitystream_digg_theme() { diff -ru activitystream//activitystream_feed/activitystream_feed.module activitystream_fr//activitystream_feed/activitystream_feed.module --- activitystream//activitystream_feed/activitystream_feed.module 2008-08-16 20:09:11.000000000 +0200 +++ activitystream_fr//activitystream_feed/activitystream_feed.module 2009-06-29 21:24:33.000000000 +0200 @@ -64,6 +64,7 @@ $feed->set_feed_url($user->feed); $feed->set_useragent('Drupal Activity Streams'); if (!$feed->init()) { + # FIXME: The first two watchdog() parameters should be literal strings. There should be no variables, concatenation, constants or even a t() call there. watchdog('activitystream', $feed->error, NULL, WATCHDOG_ERROR); return array(); } @@ -125,7 +126,7 @@ $date = theme('activitystream_date', $node->created); $user = activitystream_user_load($node->uid); $name = theme('activitystream_username', $user); - return ''. theme('activitystream_feed_icon', $activity->data) ." $name posted ". l($node->title, $activity->link) ." $date". l('#', 'node/'. $node->nid, array('class' => 'permalink')) .''."\n"; + return ''. theme('activitystream_feed_icon', $activity->data) ." $name " . t('posted') . " ". l($node->title, $activity->link) ." $date". l('#', 'node/'. $node->nid, array('class' => 'permalink')) .''."\n"; } function activitystream_feed_theme() { @@ -137,4 +138,4 @@ 'arguments' => array('activity' => NULL), ), ); -} \ No newline at end of file +} diff -ru activitystream//activitystream_flickr/activitystream_flickr.module activitystream_fr//activitystream_flickr/activitystream_flickr.module --- activitystream//activitystream_flickr/activitystream_flickr.module 2008-08-16 10:51:43.000000000 +0200 +++ activitystream_fr//activitystream_flickr/activitystream_flickr.module 2009-06-29 21:26:06.000000000 +0200 @@ -106,7 +106,7 @@ $date = theme('activitystream_date', $node->created); $user = activitystream_user_load($node->uid); $name = theme('activitystream_username', $user); - return ''. theme('activitystream_flickr_icon') ." $name posted " . l($node->title, $action->link) ." $date ". l('#', 'node/'. $node->nid, array('class' => 'permalink')) .''; + return ''. theme('activitystream_flickr_icon') ." $name " . t('posted') . " " . l($node->title, $action->link) ." $date ". l('#', 'node/'. $node->nid, array('class' => 'permalink')) .''; } diff -ru activitystream//activitystream_lastfm/activitystream_lastfm.module activitystream_fr//activitystream_lastfm/activitystream_lastfm.module --- activitystream//activitystream_lastfm/activitystream_lastfm.module 2008-08-16 10:51:43.000000000 +0200 +++ activitystream_fr//activitystream_lastfm/activitystream_lastfm.module 2009-06-29 21:37:10.000000000 +0200 @@ -62,7 +62,7 @@ $date = theme('activitystream_date', $node->created); $user = activitystream_user_load($node->uid); $name = theme('activitystream_username', $user); - return ''. theme('activitystream_lastfm_icon') ." $name listened to ". l($node->title, $activity->link) ." $date". l('#', 'node/'. $node->nid, array('class' => 'permalink')) .''; + return ''. theme('activitystream_lastfm_icon') ." $name " . t('listened to') . " " . l($node->title, $activity->link) ." $date". l('#', 'node/'. $node->nid, array('class' => 'permalink')) .''; } function activitystream_lastfm_theme() { @@ -74,4 +74,4 @@ 'arguments' => array('activity' => NULL), ), ); -} \ No newline at end of file +} diff -ru activitystream//activitystream.module activitystream_fr//activitystream.module --- activitystream//activitystream.module 2009-05-16 18:40:11.000000000 +0200 +++ activitystream_fr//activitystream.module 2009-06-29 21:15:55.000000000 +0200 @@ -6,7 +6,7 @@ * Activity Stream module */ -define('ACTIVITYSTREAM_DEFAULT_INTRO', 'Welcome to your Activity Stream setup page. You can create a lifestream by simply providing some account information for third party sites.'); +define('ACTIVITYSTREAM_DEFAULT_INTRO', t('Welcome to your Activity Stream setup page. You can create a lifestream by simply providing some account information for third party sites.')); /** * Invoke a node hook. @@ -179,7 +179,7 @@ drupal_set_title(variable_get('activitystream_title', 'Activity Stream')); $form = array(); $form['intro'] = array( - '#value' => '

' . variable_get('activitystream_user_description', t(ACTIVITYSTREAM_DEFAULT_INTRO)) . '

', + '#value' => '

' . variable_get('activitystream_user_description', ACTIVITYSTREAM_DEFAULT_INTRO) . '

', '#weight' => -10, ); @@ -213,7 +213,7 @@ $title = variable_get('activitystream_title', 'Activity Stream'); $account->content['activitystream'] = array( '#type' => 'user_profile_item', - '#title' => t($title), + '#title' => $title, '#value' => theme('activitystream', $items), '#attributes' => array('class' => 'user'), ); @@ -237,7 +237,7 @@ $output = theme('activitystream', $items); // Breadcrumb navigation - $breadcrumb[] = l(t($title), 'stream'); + $breadcrumb[] = l($title, 'stream'); drupal_set_breadcrumb($breadcrumb); $pager = theme('pager', NULL, 15, 0); if (!empty($pager)) { @@ -266,7 +266,7 @@ if ($page) { // Breadcrumb navigation - $breadcrumb[] = l(t($title), 'stream'); + $breadcrumb[] = l($title, 'stream'); $breadcrumb[] = l($user->name .'\'s '. $title, 'stream/'. $user->uid); $breadcrumb[] = l($node->nid, 'node/'); drupal_set_breadcrumb($breadcrumb); @@ -398,7 +398,7 @@ $form['activitystream_user_description'] = array( '#type' => 'textarea', '#title' => t('Description for Users'), - '#default_value' => variable_get('activitystream_user_description', t(ACTIVITYSTREAM_DEFAULT_INTRO)), + '#default_value' => variable_get('activitystream_user_description', ACTIVITYSTREAM_DEFAULT_INTRO), '#description' => t('The description that is shown to users on the page asking for their account information.'), ); @@ -507,12 +507,14 @@ node_save($node); $actions = db_query('INSERT into {activitystream} (nid, module, guid, link, data, changed) VALUES (%d,\'%s\', \'%s\',\'%s\',\'%s\', %d)', $node->nid, $name, $activity['guid'], $activity['link'], $activity['data'], $node->changed); if (!$actions) { - watchdog('activitystream', t('Cannot save stream item. Check the Drupal log for database errors.')); + watchdog('activitystream', 'Cannot save stream item. Check the Drupal log for database errors.'); return NULL; } + # FIXME: The first two watchdog() parameters should be literal strings. There should be no variables, concatenation, constants or even a t() call there. watchdog('activitystream', t('Added %title from %name', array('%title' => $node->title, '%name' => $name))); } else { node_save($node); + # FIXME: The first two watchdog() parameters should be literal strings. There should be no variables, concatenation, constants or even a t() call there. watchdog('activitystream', t('Updated %title from %name', array('%title' => $node->title, '%name' => $name))); $actions = db_query('UPDATE {activitystream} SET changed = %d', $node->changed); } @@ -568,7 +570,7 @@ switch ($delta) { case 0: $title = variable_get('activitystream_title', 'Activity Stream'); - $block['subject'] = t($title); + $block['subject'] = $title; $block['content'] = block_activitystream_content(0); break; diff -ru activitystream//activitystream_twitter/activitystream_twitter.module activitystream_fr//activitystream_twitter/activitystream_twitter.module --- activitystream//activitystream_twitter/activitystream_twitter.module 2008-08-16 10:51:43.000000000 +0200 +++ activitystream_fr//activitystream_twitter/activitystream_twitter.module 2009-06-29 21:53:28.000000000 +0200 @@ -68,7 +68,7 @@ $user = activitystream_user_load($node->uid); $title = activitystream_twitter_makelinks($node->title); $name = theme('activitystream_username', $user); - return ''. theme('activitystream_twitter_icon') ." $name ". l('tweeted', $activity->link) ." \"". $title ."\" $date". l('#', 'node/'. $node->nid, array('class' => 'permalink')) .''; + return ''. theme('activitystream_twitter_icon') ." $name ". l(t('tweeted'), $activity->link) ." \"". $title ."\" $date". l('#', 'node/'. $node->nid, array('class' => 'permalink')) .''; } function activitystream_twitter_makelinks($text) { Only in activitystream_fr/: translations