Descriptions from exif data with only whitespeces are considered empty
I noticed that pictures taken with Ubuntu-Touch have whitespace in one of the fields This should just be ignored imo
This commit is contained in:
parent
8c761942b1
commit
56227ef7ba
3 changed files with 21 additions and 0 deletions
|
|
@ -35,6 +35,8 @@ defmodule Pleroma.Upload.Filter.Exiftool.ReadDescription do
|
|||
{tag_content, 0} =
|
||||
System.cmd("exiftool", ["-b", "-s3", tag, file], stderr_to_stdout: true, parallelism: true)
|
||||
|
||||
tag_content = String.trim(tag_content)
|
||||
|
||||
if tag_content != "" and
|
||||
String.length(tag_content) <=
|
||||
Pleroma.Config.get([:instance, :description_limit]),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue