summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSarven Capadisli <csarven@status.net>2009-12-31 16:19:49 +0000
committerSarven Capadisli <csarven@status.net>2009-12-31 16:19:49 +0000
commite06292c2a2715de5af29704eebeadc1e4b05b079 (patch)
tree15535f3a3cd4b367cd5e6ea357bec642a2095cf1
parent5103cb670a93a2f03e56230f50b8abe754b019d9 (diff)
If UA doens't support navigation.geolocation or have JavaScript
enabled, the user should still be able to enable/disable their share location setting per notice.
-rw-r--r--js/util.js4
1 files changed, 1 insertions, 3 deletions
diff --git a/js/util.js b/js/util.js
index 46efe92ff..7005d3125 100644
--- a/js/util.js
+++ b/js/util.js
@@ -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();
}
}
},