Update app.py
Browse filesAjustando chave vazia da S3
app.py
CHANGED
@@ -12,7 +12,9 @@ def check_image_similarity(photo_shoot_id):
|
|
12 |
|
13 |
images = []
|
14 |
for file in files:
|
15 |
-
|
|
|
|
|
16 |
|
17 |
return ImageSimilarity(1).check(images)
|
18 |
|
|
|
12 |
|
13 |
images = []
|
14 |
for file in files:
|
15 |
+
params = file['Key'].split('/')
|
16 |
+
if params[-1] != '' and params[-1] != ' ':
|
17 |
+
images.append(AwsService.get_image_from_s3(os.environ.get('AWS_S3_BUCKET'), file['Key']))
|
18 |
|
19 |
return ImageSimilarity(1).check(images)
|
20 |
|