Commit 5a72a259 authored by Hannes Mannerheim's avatar Hannes Mannerheim

Bug, attachments stored double in file table

This if-statement looked like this before:

if (empty($file_redir))

and so it needs a ! when rewritten as instanceof
parent c2998e26
......@@ -132,7 +132,7 @@ class MediaFile
{
$file_redir = File_redirection::getKV('url', $url);
if ($file_redir instanceof File_redirection) {
if (!$file_redir instanceof File_redirection) {
$file_redir = new File_redirection;
$file_redir->url = $url;
$file_redir->file_id = $file_id;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment