]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
If UA doens't support navigation.geolocation or have JavaScript
authorSarven Capadisli <csarven@status.net>
Thu, 31 Dec 2009 16:19:49 +0000 (16:19 +0000)
committerSarven Capadisli <csarven@status.net>
Thu, 31 Dec 2009 16:19:49 +0000 (16:19 +0000)
enabled, the user should still be able to enable/disable their share
location setting per notice.

js/util.js

index 46efe92ffe9887f067d7815a04c13136a5312102..7005d3125ec0d0ed96a2b9e79b140bbd00c3c623 100644 (file)
@@ -439,7 +439,7 @@ var SN = { // StatusNet
 
         NoticeLocationAttach: function() {
             if ($('#notice_data-location_enabled').length > 0) {
-                if(navigator.geolocation) {
+                if (navigator.geolocation) {
                     $('#notice_data-location_enabled').change(function() {
                         $.cookie(SN.C.S.NoticeLocationCookieName, $('#notice_data-location_enabled').attr('checked'));
                         if($('#notice_data-location_enabled').attr('checked')) {
@@ -472,8 +472,6 @@ var SN = { // StatusNet
                     var cookieVal = $.cookie(SN.C.S.NoticeLocationCookieName);
                     $('#notice_data-location_enabled').attr('checked',(cookieVal == null || cookieVal == 'true'));
                     $('#notice_data-location_enabled').change();
-                } else {
-                    $('#notice_data-location_enabled_container').remove();
                 }
             }
         },