[extensions-web] js: Don't load the extensions list if we're not on the extensions list page



commit 1063f1f2dbdd5d4ded757ba876205a85d62b93ef
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Mon Dec 19 11:00:03 2011 -0500

    js: Don't load the extensions list if we're not on the extensions list page

 sweettooth/static/js/paginator.js |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/sweettooth/static/js/paginator.js b/sweettooth/static/js/paginator.js
index 579078c..e1a41d6 100644
--- a/sweettooth/static/js/paginator.js
+++ b/sweettooth/static/js/paginator.js
@@ -35,6 +35,9 @@ define(['jquery', 'jquery.hashchange'], function($) {
     }
 
     $.fn.paginatorify = function(url, context) {
+        if (!this.length)
+            return this;
+
         var hashParams = {};
 
         if (context === undefined)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]