alex / alex/django-admin-histograms

django_histogram.utils.Histogram assert statement is invalid

Abierto
#2 0 comentarios 1 reacción 0 asignados Ver en GitHub
Lenguaje dominante
Python
Estrellas
106
Forks
9
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

```
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"
```

Guía de contribución

No hay ninguna guía de contribución indexada para este repositorio

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.