Skip to content

Commit

Permalink
make local_directory a global variable to allow saving of external vi…
Browse files Browse the repository at this point in the history
…deo links, fixes #1350
  • Loading branch information
kamaulynder committed Apr 22, 2014
1 parent 16ac036 commit 6a55f70
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion application/helpers/reports.php
Original file line number Diff line number Diff line change
Expand Up @@ -518,13 +518,13 @@ public static function save_media($post, $incident)
// Okay, now we have these three different files on the server, now check to see
// if we should be dropping them on the CDN

$local_directory = rtrim($upload_dir, '/').'/';
if ($media_medium AND $media_thumb AND Kohana::config("cdn.cdn_store_dynamic_content"))
{
$cdn_media_medium = cdn::upload($media_medium);
$cdn_media_thumb = cdn::upload($media_thumb);

// We no longer need the files we created on the server. Remove them.
$local_directory = rtrim($upload_dir, '/').'/';

if (file_exists($local_directory.$media_medium))
{
Expand Down

0 comments on commit 6a55f70

Please sign in to comment.