Skip to content

Interactive interface for browsing global, full-resolution satellite imagery

change var names #2551

Benjamin Kingee3c91ea7c45
diff --git a/web/js/util/util.js b/web/js/util/util.js
index 8e7ac6bb4..059c2d8a8 100644
--- a/web/js/util/util.js
+++ b/web/js/util/util.js
@@ -1042,9 +1042,9 @@ export default (function(self) {
* @return normalized longitude value
*/
self.normalizeWrappedLongitude = function(longitude) {
- const negative = longitude < 0;
- const value = longitude % 360;
- return negative && value < -180 ? value + 360 : !negative && value > 180 ? value - 360 : value;
+ const isNegative = longitude < 0;
+ const remainder = longitude % 360;
+ return isNegative && remainder < -180 ? remainder + 360 : !isNegative && remainder > 180 ? remainder - 360 : remainder;
};
// Allows simple printf functionality with strings
// arguments array contains all args passed. String must be formatted