1
0
Fork 0

pylint: Return 'None' when end of function is reached

Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
merge-requests/774/head
Vasilis Tsiligiannis 2019-09-24 20:33:59 +03:00
parent d24f0d03ee
commit f5f6d0a0fd
3 changed files with 1 additions and 2 deletions

View File

@ -19,7 +19,6 @@ disable=
R0913,
R0914,
R0915,
R1710,
W0201,
W0221,
W0223,

View File

@ -19,7 +19,6 @@ disable=
R0913,
R0914,
R0915,
R1710,
W0201,
W0221,
W0223,

View File

@ -21,6 +21,7 @@ class HasStationListFilter(admin.SimpleListFilter):
return queryset.annotate(count=Count('ground_stations')).filter(count__gt=0)
if self.value() == '0':
return queryset.annotate(count=Count('ground_stations')).filter(count__lt=1)
return None
class UserAdmin(AuthUserAdmin):