Skip to content

Commit 4347aea

Browse files
committed
- last lookup
1 parent 1d48087 commit 4347aea

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

djangodav/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,5 @@
1919
# You should have received a copy of the GNU Affero General Public License
2020
# along with DjangoDav. If not, see <http://www.gnu.org/licenses/>.
2121

22-
VERSION = (0, 0, 1, 'beta', 16)
22+
VERSION = (0, 0, 1, 'beta', 17)
2323
__version__ = "0.0.1b16"

djangodav/db/resources.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ def get_model_by_path(self, model_attr, path):
167167
if related:
168168
qs = qs.select_related(*related)
169169
try:
170-
return qs.filter(reduce(and_, args)).last()
170+
return qs.filter(reduce(and_, args))[0]
171171
except IndexError:
172172
raise qs.model.DoesNotExist()
173173

0 commit comments

Comments
 (0)