Skip to content

Commit

Permalink
! Getting "The database value you're trying to insert does not exist:…
Browse files Browse the repository at this point in the history
… id_file" on embedded files in the gallery. (Subs-Media.php)
  • Loading branch information
Nao committed Jul 25, 2017
1 parent 14d6a15 commit 6ec1c96
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/app/media/Subs-Media.php
Expand Up @@ -2960,7 +2960,7 @@ function aeva_fillMediaArray($request, $all_albums = true)
'transparent' => isset($row['transparency']) && $row['transparency'] == 'transparent',
'thumb_url' => isset($row['thumb_dir']) && !empty($amSettings['clear_thumbnames']) ? $clearurl . '/' . str_replace('%2F', '/', urlencode($row['thumb_dir'])) . '/' . aeva_getEncryptedFilename($row['thumb_file'], $row['id_thumb'], true) : $galurl . 'sa=media;in=' . $row['id_media'] . ';thumb',
);
if ($row['transparency'] == '')
if ($row['transparency'] == '' && $row['type'] == 'image')
{
$path = $clearurl . '/' . str_replace('%2F', '/', urlencode($row['thumb_dir'])) . '/' . aeva_getEncryptedFilename($row['thumb_file'], $row['id_thumb'], true);
$items[$row['id_media']]['transparent'] = aeva_resetTransparency($row['id_thumb'], $path);
Expand Down

0 comments on commit 6ec1c96

Please sign in to comment.