예제 #1
0
/**
 * Get attachments
 *
 * @param \ElggObject $object Wall or wire post
 * @param string      $format links|icons or null for an array of entities
 * @param size        $size   Icon size
 * @return string
 */
function get_attachments($object, $format = null, $size = 'small')
{
    if ($object instanceof Post) {
        return $object->getAttachments($format, $size);
    }
    return '';
}