aboutsummaryrefslogtreecommitdiffstats
path: root/mod/profile_photo.php
diff options
context:
space:
mode:
authorThomas Willingham <founder@kakste.com>2013-12-18 18:21:47 +0000
committerThomas Willingham <founder@kakste.com>2013-12-18 18:21:47 +0000
commit7ac00d02d110ec2f2d33779d8316e17c13cda149 (patch)
tree03b41e86e0790895fe56488beea2b5f554fbaeae /mod/profile_photo.php
parent733cb37ef14eb4dd5408e1a8c453f13cd41952eb (diff)
parentdf34aaba4733b1c38ac2b8b9c19c5a945d5a841b (diff)
downloadvolse-hubzilla-7ac00d02d110ec2f2d33779d8316e17c13cda149.tar.gz
volse-hubzilla-7ac00d02d110ec2f2d33779d8316e17c13cda149.tar.bz2
volse-hubzilla-7ac00d02d110ec2f2d33779d8316e17c13cda149.zip
Merge remote-tracking branch 'upstream/master'
Conflicts: mod/page.php
Diffstat (limited to 'mod/profile_photo.php')
-rw-r--r--mod/profile_photo.php16
1 files changed, 3 insertions, 13 deletions
diff --git a/mod/profile_photo.php b/mod/profile_photo.php
index f8eda43cf..876e3a931 100644
--- a/mod/profile_photo.php
+++ b/mod/profile_photo.php
@@ -14,16 +14,6 @@ function profile_photo_init(&$a) {
}
-function profile_photo_aside(&$a) {
-
- if(! local_user()) {
- return;
- }
-
- profile_create_sidebar($a);
-}
-
-
function profile_photo_post(&$a) {
if(! local_user()) {
@@ -42,7 +32,7 @@ function profile_photo_post(&$a) {
intval($_REQUEST['profile']),
intval(local_user())
);
- if(count($r) && (! intval($r[0]['is_default'])))
+ if(($r) && (! intval($r[0]['is_default'])))
$is_default_profile = 0;
}
@@ -119,7 +109,7 @@ function profile_photo_post(&$a) {
dbesc($base_image['resource_id']),
intval(local_user())
);
- $r = q("UPDATE photo SET ( photo_flags ^ %d ) WHERE (photo_flags & %d )
+ $r = q("UPDATE photo SET photo_flags = ( photo_flags ^ %d ) WHERE ( photo_flags & %d )
AND resource_id != '%s' AND `uid` = %d",
intval(PHOTO_PROFILE),
intval(PHOTO_PROFILE),
@@ -236,7 +226,7 @@ function profile_photo_content(&$a) {
// unset any existing profile photos
$r = q("UPDATE photo SET profile = 0 WHERE profile = 1 AND uid = %d",
intval(local_user()));
- $r = q("UPDATE photo SET (photo_flags ^ %d ) WHERE (photo_flags & %d ) AND uid = %d",
+ $r = q("UPDATE photo SET photo_flags = (photo_flags ^ %d ) WHERE (photo_flags & %d ) AND uid = %d",
intval(PHOTO_PROFILE),
intval(PHOTO_PROFILE),
intval(local_user()));