I've got the realnames module installed and in the subscriptions block it has a checkbox with "Posts by markshep" next to it, but I want it to say "Posts by Mark Sheppard" instead. Here's a patch which seems to work:

--- sites/all/modules/notifications/notifications_content/notifications_content.module~ 2010-10-21 07:34:59.000000000 +0000
+++ sites/all/modules/notifications/notifications_content/notifications_content.module  2011-09-26 22:23:27.000000000 +0000
@@ -608,8 +608,9 @@
   }
   // Author
   if (notifications_content_type_enabled($node->type, 'author')) {
+    $user = user_load(array('uid' => $node->uid));
     $options[] = array(
-      'name' => t('Posts by @name', array('@name' => $node->name)),
+      'name' => t('Posts by @name', array('@name' => theme("username", $user))),
       'type' => 'author',
       'fields' => array('author' => $node->uid),
     );

However I know virtually nothing about Drupal internals so there could well be a better way of doing this!

Comments

Littlebob’s picture

I'm also having the exact same problem. Does anyone else here see a problem with the above method? I only see the slight overhead of the extra user lookup.