← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] lp:~bac/launchpad/bug-781987 into lp:launchpad

 

Brad Crittenden has proposed merging lp:~bac/launchpad/bug-781987 into lp:launchpad.

Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)
Related bugs:
  Bug #781987 in Launchpad itself: "when a bug has no subscribers the list is shown as 'None'"
  https://bugs.launchpad.net/launchpad/+bug/781987

For more details, see:
https://code.launchpad.net/~bac/launchpad/bug-781987/+merge/61459

= Summary =

When a bug had no subscribers the word "None" was used, which looked a
little sparse.  It now reads "No subscribers."

== Tests ==

lib/lp/bugs/javascript/tests/test_subscribers_list.html

== Demo and Q/A ==

Look at http://launchpad.dev/bugs/3

= Launchpad lint =

Checking for conflicts and issues in changed files.

Linting changed files:
  lib/lp/bugs/templates/bug-portlet-subscribers-content.pt
  lib/lp/bugs/templates/bugtask-edit-form.pt
  lib/lp/bugs/javascript/bugtask_index_portlets.js
  lib/lp/bugs/javascript/subscribers_list.js
  lib/lp/code/javascript/branch.subscription.js
  lib/lp/bugs/javascript/tests/test_subscribers_list.js
-- 
https://code.launchpad.net/~bac/launchpad/bug-781987/+merge/61459
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~bac/launchpad/bug-781987 into lp:launchpad.
=== modified file 'lib/lp/bugs/javascript/bugtask_index_portlets.js'
--- lib/lp/bugs/javascript/bugtask_index_portlets.js	2011-05-12 14:59:21 +0000
+++ lib/lp/bugs/javascript/bugtask_index_portlets.js	2011-05-18 18:46:19 +0000
@@ -548,7 +548,7 @@
         if (next) {
             subscribers.insertBefore(link_node, next);
         } else {
-            // Handle the case of the displayed "None".
+            // Handle the case of no subscribers.
             var none_subscribers = Y.one('#none-subscribers');
             if (none_subscribers) {
                 var none_parent = none_subscribers.get('parentNode');
@@ -760,7 +760,7 @@
                 }
 
                 // Handle the case where the subscriber's list displays
-                // "None".
+                // "No subscribers."
                 var empty_subscribers = Y.one("#none-subscribers");
                 if (empty_subscribers) {
                     var parent = empty_subscribers.get('parentNode');
@@ -1469,7 +1469,7 @@
     if (next) {
         subscribers.insertBefore(link_node, next);
     } else {
-        // Handle the case of the displayed "None".
+        // Handle the case of no subscribers.
         var none_subscribers = Y.one('#none-subscribers');
         if (none_subscribers) {
             var none_parent = none_subscribers.get('parentNode');

=== modified file 'lib/lp/bugs/javascript/subscribers_list.js'
--- lib/lp/bugs/javascript/subscribers_list.js	2011-04-28 14:42:41 +0000
+++ lib/lp/bugs/javascript/subscribers_list.js	2011-05-18 18:46:19 +0000
@@ -26,7 +26,8 @@
     // then the list of subscribers is empty.
     if (!Y.Lang.isValue(subscriber_list.one('div')) &&
         !Y.Lang.isValue(Y.one('#none-subscribers'))) {
-        var none_div = Y.Node.create('<div id="none-subscribers">None</div>');
+        var none_div = Y.Node.create(
+            '<div id="none-subscribers">No subscribers.</div>');
         var subscribers = subscriber_list.get('parentNode');
         subscribers.appendChild(none_div);
     }

=== modified file 'lib/lp/bugs/javascript/tests/test_subscribers_list.js'
--- lib/lp/bugs/javascript/tests/test_subscribers_list.js	2011-04-28 14:56:23 +0000
+++ lib/lp/bugs/javascript/tests/test_subscribers_list.js	2011-05-18 18:46:19 +0000
@@ -57,7 +57,7 @@
         module._reset();
         var none_node = subscribers_list.one('#none-subscribers');
         Y.Assert.isNotNull(none_node);
-        Y.Assert.areEqual('None', none_node.get('innerHTML'));
+        Y.Assert.areEqual('No subscribers.', none_node.get('innerHTML'));
         Y.Assert.areEqual(subscribers_list,
                           none_node.get('parentNode'));
 
@@ -205,7 +205,7 @@
         this.wait(function() {
             // There is no subscriber link anymore.
             Y.Assert.isNull(this.root.one('.' + person.get('css_name')));
-            // And the reset() call adds the "None" node.
+            // And the reset() call adds the "No subscribers" node.
             Y.Assert.isNotNull(this.root.one('#none-subscribers'));
         }, 1100);
     },

=== modified file 'lib/lp/bugs/templates/bug-portlet-subscribers-content.pt'
--- lib/lp/bugs/templates/bug-portlet-subscribers-content.pt	2011-04-21 18:11:51 +0000
+++ lib/lp/bugs/templates/bug-portlet-subscribers-content.pt	2011-05-18 18:46:19 +0000
@@ -46,7 +46,8 @@
       </div>
       </div>
       <div id="none-subscribers"
-        tal:condition="not:direct_subscriptions">None</div>
+        tal:condition="not:direct_subscriptions">
+        No subscribers.</div>
   </div>
   <div id="subscribers-from-duplicates-container">
     <a id="subscribers-from-dupes-content-link"

=== modified file 'lib/lp/bugs/templates/bugtask-edit-form.pt'
--- lib/lp/bugs/templates/bugtask-edit-form.pt	2010-05-21 13:44:43 +0000
+++ lib/lp/bugs/templates/bugtask-edit-form.pt	2011-05-18 18:46:19 +0000
@@ -187,16 +187,14 @@
         <td title="Changeable only by a project maintainer or bug supervisor">
           <span
             tal:condition="not:view/userCanEditImportance"
-            class="sprite read-only"
-          />
+            class="sprite read-only"></span>
           <tal:widget content="structure view/widgets/importance" />
         </td>
         <td tal:condition="view/widgets/milestone"
             title="Changeable only by a project maintainer or bug supervisor">
           <span
             tal:condition="not:view/userCanEditMilestone"
-            class="sprite read-only"
-          />
+            class="sprite read-only"></span>
           <tal:widget content="structure view/widgets/milestone" />
         </td>
       </tr>
@@ -233,7 +231,7 @@
         The information about this bug in Launchpad is
         automatically pulled daily from the remote bug.
         <tal:has_bugwatch tal:condition="context/bugwatch">
-          <tal:has_been_pulled 
+          <tal:has_been_pulled
               tal:condition="context/bugwatch/lastchecked">
               This information was last pulled
               <b
@@ -242,7 +240,7 @@
                 3 minutes ago
               </b>.
           </tal:has_been_pulled>
-          <tal:has_not_been_pulled 
+          <tal:has_not_been_pulled
               tal:condition="not:context/bugwatch/lastchecked">
             This information hasn't been pulled yet.
           </tal:has_not_been_pulled>

=== modified file 'lib/lp/code/javascript/branch.subscription.js'
--- lib/lp/code/javascript/branch.subscription.js	2011-04-19 15:16:58 +0000
+++ lib/lp/code/javascript/branch.subscription.js	2011-05-18 18:46:19 +0000
@@ -115,7 +115,7 @@
                 if (next) {
                     subscribers.insertBefore(link_node, next);
                 } else {
-                    // Handle the case of the displayed "None".
+                    // Handle the case of no subscribers.
                     var none_subscribers = Y.one('#none-subscribers');
                     if (none_subscribers) {
                         var none_parent = none_subscribers.get('parentNode');