mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-17 04:05:16 +02:00
bad checkin
This commit is contained in:
parent
ed5768c4a3
commit
886c3d1472
2 changed files with 6 additions and 7 deletions
|
@ -819,12 +819,12 @@ function add_fcontact($arr,$update = false) {
|
|||
}
|
||||
|
||||
|
||||
function scale_external_images($s, $include_link = true, $scale_replace = false) {
|
||||
function scale_external_images($srctext, $include_link = true, $scale_replace = false) {
|
||||
|
||||
$a = get_app();
|
||||
|
||||
// Picture addresses can contain special characters
|
||||
$s = htmlspecialchars_decode($s);
|
||||
$s = htmlspecialchars_decode($srctext);
|
||||
|
||||
$matches = null;
|
||||
$c = preg_match_all('/\[img.*?\](.*?)\[\/img\]/ism',$s,$matches,PREG_SET_ORDER);
|
||||
|
@ -846,7 +846,9 @@ function scale_external_images($s, $include_link = true, $scale_replace = false)
|
|||
$scaled = str_replace($scale_replace[0], $scale_replace[1], $mtch[1]);
|
||||
else
|
||||
$scaled = $mtch[1];
|
||||
$i = fetch_url($scaled);
|
||||
$i = @fetch_url($scaled);
|
||||
if(! $i)
|
||||
return $srctext;
|
||||
|
||||
$cachefile = get_cachefile(hash("md5", $scaled));
|
||||
if ($cachefile != '') {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue