aboutsummaryrefslogtreecommitdiff
path: root/mod
diff options
context:
space:
mode:
authorMatt Beckett <beck24@gmail.com>2013-09-26 13:36:17 -0700
committerMatt Beckett <beck24@gmail.com>2013-09-26 13:36:17 -0700
commit1150f831637c87322fcc85cb59758805d48c90e0 (patch)
tree9cc547318bdaaa8a27c5a5c6e7a7c1e359811e05 /mod
parent96fd62420124d8b22e9a368532240a5c5066d628 (diff)
downloadelgg-1150f831637c87322fcc85cb59758805d48c90e0.tar.gz
elgg-1150f831637c87322fcc85cb59758805d48c90e0.tar.bz2
Fix redeclaring $size variable - breaks user icon if filesize == 0 or the file somehow no longer exists
Diffstat (limited to 'mod')
-rw-r--r--mod/profile/icondirect.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/mod/profile/icondirect.php b/mod/profile/icondirect.php
index dbab5d31f..85221945a 100644
--- a/mod/profile/icondirect.php
+++ b/mod/profile/icondirect.php
@@ -55,8 +55,8 @@ if ($mysql_dblink) {
$user_path = date('Y/m/d/', $join_date) . $guid;
$filename = "$data_root$user_path/profile/{$guid}{$size}.jpg";
- $size = @filesize($filename);
- if ($size) {
+ $filesize = @filesize($filename);
+ if ($filesize) {
header("Content-type: image/jpeg");
header('Expires: ' . gmdate('D, d M Y H:i:s \G\M\T', strtotime("+6 months")), true);
header("Pragma: public");