Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix error message for unique constraints

  • Loading branch information...
commit e3c9742cd462706d4da76fcdd6ede7dd1354ad6c 1 parent 1a6d077
@andrewgodwin andrewgodwin authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  django/db/backends/schema.py
View
2  django/db/backends/schema.py
@@ -384,7 +384,7 @@ def alter_field(self, model, old_field, new_field, strict=False):
# Find the unique constraint for this field
constraint_names = self._constraint_names(model, [old_field.column], unique=True)
if strict and len(constraint_names) != 1:
- raise ValueError("Found wrong number (%s) of constraints for %s.%s" % (
+ raise ValueError("Found wrong number (%s) of unique constraints for %s.%s" % (
len(constraint_names),
model._meta.db_table,
old_field.column,
Please sign in to comment.
Something went wrong with that request. Please try again.