alex / alex/django-admin-histograms
django_histogram.utils.Histogram assert statement is invalid
Offen
- Vorherrschende Sprache
- Python
- Sterne
- 106
- Forks
- 9
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
```
assert months or days, 'You must pass either months or days, not both.'
```
The above line check to see that months or days is in the list of args. It doesn't actually check that only one is used. This would work instead:
```
assert months or days, "You must have months or days"
assert not (months and days), "You must pass either months or days, not both"
```
Beitragsleitfaden
Für dieses Repository ist kein Beitragsleitfaden indexiert
Bewertung
Dieses Issue wurde noch nicht bewertet.