diff options
author | Brion Vibber <brion@status.net> | 2010-11-08 13:27:54 -0800 |
---|---|---|
committer | Brion Vibber <brion@status.net> | 2010-11-08 13:27:54 -0800 |
commit | 883f7a6c0b1464f6723e51bf99d06641a612f968 (patch) | |
tree | 59c2d6cf81a84d629098e69d52456081fdbed333 /classes | |
parent | 719b480eaaa3459497c008839606a96cc8f368e1 (diff) |
Avoid marking files as attachments that are not locally uploaded, unless they're really oembedable. HTML-y things now excluded properly.
Diffstat (limited to 'classes')
-rw-r--r-- | classes/File.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/classes/File.php b/classes/File.php index 16e00024a..d71403e64 100644 --- a/classes/File.php +++ b/classes/File.php @@ -352,6 +352,9 @@ class File extends Memcached_DataObject $mimetype = substr($mimetype,0,$semicolon); } if(in_array($mimetype,$notEnclosureMimeTypes)){ + // Never treat HTML as an enclosure type! + return false; + } else { $oembed = File_oembed::staticGet('file_id',$this->id); if($oembed){ $mimetype = strtolower($oembed->mimetype); |