Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Changed get_object() not to use 'ordering' parameter from the model. …

…Thanks, Ned Batchelder

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 79633b280c7ba614b1b54a234e46d7cc35b36c42 1 parent f8915c0
@adrianholovaty adrianholovaty authored
Showing with 1 addition and 0 deletions.
  1. +1 −0  django/core/meta/
1  django/core/meta/
@@ -1352,6 +1352,7 @@ def _get_where_clause(lookup_type, table_prefix, field_name, value):
raise TypeError, "Got invalid lookup_type: %s" % repr(lookup_type)
def function_get_object(opts, klass, does_not_exist_exception, **kwargs):
+ kwargs['order_by'] = ()
obj_list = function_get_list(opts, klass, **kwargs)
if len(obj_list) < 1:
raise does_not_exist_exception, "%s does not exist for %s" % (opts.object_name, kwargs)
Please sign in to comment.
Something went wrong with that request. Please try again.