From f39b0421b406b411c3bcb58e8aa415d885fea505 Mon Sep 17 00:00:00 2001 From: Diego Guimarães Date: Mon, 8 Sep 2014 19:38:07 +0200 Subject: Fixed #23338 -- Added warning when unique=True on ForeigKey MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Thanks Jonathan Lindén for the initial patch, and Tim Graham and Gabe Jackson for the suggestions. --- docs/ref/checks.txt | 2 ++ 1 file changed, 2 insertions(+) (limited to 'docs/ref') diff --git a/docs/ref/checks.txt b/docs/ref/checks.txt index 86b287c0f2..03e74ecd1a 100644 --- a/docs/ref/checks.txt +++ b/docs/ref/checks.txt @@ -154,6 +154,8 @@ Related Fields * **fields.E339**: ``.`` is not a foreign key to ````. * **fields.W340**: ``null`` has no effect on ``ManyToManyField``. * **fields.W341**: ``ManyToManyField`` does not support ``validators``. +* **fields.W342**: Setting ``unique=True`` on a ``ForeignKey`` has the same + effect as using a ``OneToOneField``. Signals ~~~~~~~ -- cgit v1.3