mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-11-27 13:47:58 +01:00
fix(Philomena.DuplicateReports.SearchQuery): validate_required in image_changeset
This commit is contained in:
parent
99958ee941
commit
5def18e5f0
1 changed files with 10 additions and 0 deletions
|
@ -37,6 +37,16 @@ defmodule Philomena.DuplicateReports.SearchQuery do
|
|||
:image_aspect_ratio,
|
||||
:uploaded_image
|
||||
])
|
||||
|> validate_required([
|
||||
:image_width,
|
||||
:image_height,
|
||||
:image_format,
|
||||
:image_duration,
|
||||
:image_mime_type,
|
||||
:image_is_animated,
|
||||
:image_aspect_ratio,
|
||||
:uploaded_image
|
||||
])
|
||||
|> validate_number(:image_width, greater_than: 0)
|
||||
|> validate_number(:image_height, greater_than: 0)
|
||||
|> validate_inclusion(
|
||||
|
|
Loading…
Reference in a new issue