From e37d7e90f0670a1b224dca50c283bf406f1105de Mon Sep 17 00:00:00 2001 From: Don Cross Date: Sat, 22 Jun 2019 21:15:54 -0400 Subject: [PATCH] Trim trailing whitespace from python code. --- generate/makedoc | 2 +- generate/template/astronomy.py | 2 +- source/python/astronomy.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/generate/makedoc b/generate/makedoc index 7bf1589b..d967f1a3 100755 --- a/generate/makedoc +++ b/generate/makedoc @@ -6,7 +6,7 @@ Fail() } echo "Trimming trailing whitespace in source code." -for file in template/astronomy.js template/astronomy.c ../source/c/astronomy.h; do +for file in template/astronomy.{js,c,py} ../source/c/astronomy.h; do node trimspace.js ${file} done diff --git a/generate/template/astronomy.py b/generate/template/astronomy.py index 9c487f63..4559784f 100644 --- a/generate/template/astronomy.py +++ b/generate/template/astronomy.py @@ -134,7 +134,7 @@ def _DeltaT(mjd): if mjd <= _DT[0].mjd: return _DT[0].dt if mjd >= _DT[-1].mjd: - return _DT[-1].dt + return _DT[-1].dt # Do a binary search to find the pair of indexes this mjd lies between. lo = 0 hi = len(_DT) - 2 # Make sure there is always an array element after the one we are looking at. diff --git a/source/python/astronomy.py b/source/python/astronomy.py index 21c6398e..1397276f 100644 --- a/source/python/astronomy.py +++ b/source/python/astronomy.py @@ -225,7 +225,7 @@ def _DeltaT(mjd): if mjd <= _DT[0].mjd: return _DT[0].dt if mjd >= _DT[-1].mjd: - return _DT[-1].dt + return _DT[-1].dt # Do a binary search to find the pair of indexes this mjd lies between. lo = 0 hi = len(_DT) - 2 # Make sure there is always an array element after the one we are looking at.