Mercurial > hgrepos > Python > libs > ConfigMix
comparison configmix/config.py @ 516:ad1e630ba736
FIX: Do not filter-out all False values then interpolating (zero int, boolean False)
| author | Franz Glasner <fzglas.hg@dom66.de> |
|---|---|
| date | Sun, 19 Dec 2021 14:36:18 +0100 |
| parents | 3387a9d5fb12 |
| children | 328af767f5f8 |
comparison
equal
deleted
inserted
replaced
| 515:3387a9d5fb12 | 516:ad1e630ba736 |
|---|---|
| 779 # Dont apply and type conversions to the variable value if | 779 # Dont apply and type conversions to the variable value if |
| 780 # the whole `s` is just one expansion | 780 # the whole `s` is just one expansion |
| 781 # | 781 # |
| 782 if (start == 0) and (rest == len_s): | 782 if (start == 0) and (rest == len_s): |
| 783 return varvalue | 783 return varvalue |
| 784 if not varvalue: | 784 if varvalue is None: |
| 785 # None and/or empty str are handled equally here | |
| 786 pass | 785 pass |
| 787 else: | 786 else: |
| 788 res_append(str_and_u(varvalue)) | 787 res_append(str_and_u(varvalue)) |
| 789 # don't re-evaluate because `self.getvar_s()` expands already | 788 # don't re-evaluate because `self.getvar_s()` expands already |
| 790 start = s.find(_STARTTOK, rest) | 789 start = s.find(_STARTTOK, rest) |
