[PATCH] models: Make series.project nullable

Andy Doan andy.doan at linaro.org
Fri Feb 24 14:37:28 AEDT 2017


On 02/07/2017 03:56 PM, Stephen Finucane wrote:
> This is reflected in the migration but not the model.
>
> Signed-off-by: Stephen Finucane <stephen at that.guru>
> Fixes: c1d8a0d ("Fix series.project migration logic")
> Cc: Andy Doan <andy.doan at linaro.org>

Good catch - sorry I missed that.

Reviewed-by: Andy Doan <andy.doan at linaro.org>

> ---
>  patchwork/models.py | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/patchwork/models.py b/patchwork/models.py
> index d698e23..cf363f0 100644
> --- a/patchwork/models.py
> +++ b/patchwork/models.py
> @@ -551,7 +551,8 @@ class Series(models.Model):
>      """An collection of patches."""
>
>      # parent
> -    project = models.ForeignKey(Project, related_name='series')
> +    project = models.ForeignKey(Project, related_name='series', null=True,
> +                                blank=True)
>
>      # content
>      cover_letter = models.ForeignKey(CoverLetter,
>



More information about the Patchwork mailing list