forked from GNUsocial/gnu-social
		
	Setting the geo location cookie expire date far into the future: 2029 ;)
This commit is contained in:
		@@ -495,7 +495,7 @@ var SN = { // StatusNet
 | 
				
			|||||||
                $('#'+SN.C.S.NoticeLocationId).val('');
 | 
					                $('#'+SN.C.S.NoticeLocationId).val('');
 | 
				
			||||||
                $('#'+SN.C.S.NoticeDataGeo).attr('checked', false);
 | 
					                $('#'+SN.C.S.NoticeDataGeo).attr('checked', false);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                $.cookie(SN.C.S.NoticeDataGeoCookie, 'disabled', { path: '/', expires: SN.U.GetDateFromNow(30) });
 | 
					                $.cookie(SN.C.S.NoticeDataGeoCookie, 'disabled', { path: '/', expires: SN.U.GetFullYear(2029, 0, 1) });
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            function getJSONgeocodeURL(geocodeURL, data) {
 | 
					            function getJSONgeocodeURL(geocodeURL, data) {
 | 
				
			||||||
@@ -538,7 +538,7 @@ var SN = { // StatusNet
 | 
				
			|||||||
                        NDG: true
 | 
					                        NDG: true
 | 
				
			||||||
                    };
 | 
					                    };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                    $.cookie(SN.C.S.NoticeDataGeoCookie, JSON.stringify(cookieValue), { path: '/', expires: SN.U.GetDateFromNow(30) });
 | 
					                    $.cookie(SN.C.S.NoticeDataGeoCookie, JSON.stringify(cookieValue), { path: '/', expires: SN.U.GetFullYear(2029, 0, 1) });
 | 
				
			||||||
                });
 | 
					                });
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -661,9 +661,9 @@ var SN = { // StatusNet
 | 
				
			|||||||
            });
 | 
					            });
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        GetDateFromNow: function(days) {
 | 
					        GetFullYear: function(year, month, day) {
 | 
				
			||||||
            var date = new Date();
 | 
					            var date = new Date();
 | 
				
			||||||
            date.setTime(date.getTime() + (days * 24 * 60 * 60 * 1000));
 | 
					            date.setFullYear(year, month, day);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            return date;
 | 
					            return date;
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user