Skip to content

Commit

Permalink
avoid unnecessary cache invalidation of a django queryset
Browse files Browse the repository at this point in the history
  • Loading branch information
dmarychev authored and Dmitry Marychev committed Jan 25, 2024
1 parent abee008 commit f13f982
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 7 deletions.
2 changes: 0 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
language: python
matrix:
include:
- python: 2.7
env: TOXENV="py27-django{1.10,1.11},flake8"
- python: 3.6
env: TOXENV="py36-django{1.10,1.11,2.0,2.1,2.2,3.0}"
- python: 3.7
Expand Down
2 changes: 1 addition & 1 deletion access/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.1.2b1"
__version__ = "0.1.2b2"
2 changes: 1 addition & 1 deletion access/plugins.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def __getattr__(self, name):

def method(queryset, request):
if request.user.is_superuser:
return queryset.all()
return queryset
return apply_method(queryset, request)
return method
raise AttributeError(name)
Expand Down
4 changes: 1 addition & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@

# Specify the Python versions you support here. In particular, ensure
# that you indicate whether you support Python 2, Python 3 or both.
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
Expand Down Expand Up @@ -129,4 +127,4 @@
# 'sample=sample:main',
# ],
#},
)
)

0 comments on commit f13f982

Please sign in to comment.