Re-use enclosure decision logic to decide if a link gets a paperclip/lightbox popup.
This commit is contained in:
parent
b46d2e7fe0
commit
2a56245614
@ -552,12 +552,13 @@ function common_linkify($url) {
|
||||
}
|
||||
|
||||
if (!empty($f)) {
|
||||
if (isset($f->filename)) {
|
||||
if ($f->isEnclosure()) {
|
||||
$is_attachment = true;
|
||||
$attachment_id = $f->id;
|
||||
} else { // if it has OEmbed info, it's an attachment, too
|
||||
} else {
|
||||
$foe = File_oembed::staticGet('file_id', $f->id);
|
||||
if (!empty($foe)) {
|
||||
// if it has OEmbed info, it's an attachment, too
|
||||
$is_attachment = true;
|
||||
$attachment_id = $f->id;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user