aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorzottel <github@zottel.net>2012-05-23 18:25:58 +0200
committerzottel <github@zottel.net>2012-05-23 18:25:58 +0200
commit3aa516ccabc9bb09ae30ffa2d3657fba36699ea9 (patch)
tree93cd7fe6c2b9b0cc5851cb8324b5f6591d990f7f /include
parente9c86c0fd0fb87b49e60669e6d4be810ca426ec4 (diff)
parent61dba985c14ebcfd20d18b579aee9b781f98bc23 (diff)
downloadvolse-hubzilla-3aa516ccabc9bb09ae30ffa2d3657fba36699ea9.tar.gz
volse-hubzilla-3aa516ccabc9bb09ae30ffa2d3657fba36699ea9.tar.bz2
volse-hubzilla-3aa516ccabc9bb09ae30ffa2d3657fba36699ea9.zip
Merge remote branch 'upstream/master'
Diffstat (limited to 'include')
-rw-r--r--include/Photo.php6
-rw-r--r--include/auth.php7
-rw-r--r--include/config.php4
-rw-r--r--include/items.php2
-rw-r--r--include/socgraph.php30
5 files changed, 32 insertions, 17 deletions
diff --git a/include/Photo.php b/include/Photo.php
index 4d02b5c65..fce559999 100644
--- a/include/Photo.php
+++ b/include/Photo.php
@@ -87,6 +87,12 @@ class Photo {
}
+ public function rotate($degrees) {
+ $this->image = imagerotate($this->image,$degrees,0);
+ $this->width = imagesx($this->image);
+ $this->height = imagesy($this->image);
+ }
+
public function scaleImageUp($min) {
diff --git a/include/auth.php b/include/auth.php
index 1341f3bb8..b87662fea 100644
--- a/include/auth.php
+++ b/include/auth.php
@@ -11,6 +11,13 @@ function nuke_session() {
unset($_SESSION['cid']);
unset($_SESSION['theme']);
unset($_SESSION['page_flags']);
+ unset($_SESSION['submanage']);
+ unset($_SESSION['my_url']);
+ unset($_SESSION['my_address']);
+ unset($_SESSION['addr']);
+ unset($_SESSION['return_url']);
+ unset($_SESSION['theme']);
+ unset($_SESSION['page_flags']);
}
diff --git a/include/config.php b/include/config.php
index 4cff38090..12fc9cafc 100644
--- a/include/config.php
+++ b/include/config.php
@@ -77,11 +77,9 @@ function get_config($family, $key, $instore = false) {
if(! function_exists('set_config')) {
function set_config($family,$key,$value) {
global $a;
-
// manage array value
$dbvalue = (is_array($value)?serialize($value):$value);
- $dbvalue = (is_bool($value) ? intval($value) : $value);
-
+ $dbvalue = (is_bool($dbvalue) ? intval($dbvalue) : $dbvalue);
if(get_config($family,$key,true) === false) {
$a->config[$family][$key] = $value;
$ret = q("INSERT INTO `config` ( `cat`, `k`, `v` ) VALUES ( '%s', '%s', '%s' ) ",
diff --git a/include/items.php b/include/items.php
index 91c9056fe..e5b640fd2 100644
--- a/include/items.php
+++ b/include/items.php
@@ -1010,7 +1010,7 @@ function tag_deliver($uid,$item_id) {
'otype' => 'item'
));
- if((! $community_page) && (! prvgroup))
+ if((! $community_page) && (! $prvgroup))
return;
diff --git a/include/socgraph.php b/include/socgraph.php
index 592779089..eccb133cc 100644
--- a/include/socgraph.php
+++ b/include/socgraph.php
@@ -71,20 +71,24 @@ function poco_load($cid,$uid = 0,$zcid = 0,$url = null) {
$name = $entry->displayName;
- foreach($entry->urls as $url) {
- if($url->type == 'profile') {
- $profile_url = $url->value;
- continue;
- }
- if($url->type == 'webfinger') {
- $connect_url = str_replace('acct:' , '', $url->value);
- continue;
+ if(isset($entry->urls)) {
+ foreach($entry->urls as $url) {
+ if($url->type == 'profile') {
+ $profile_url = $url->value;
+ continue;
+ }
+ if($url->type == 'webfinger') {
+ $connect_url = str_replace('acct:' , '', $url->value);
+ continue;
+ }
}
- }
- foreach($entry->photos as $photo) {
- if($photo->type == 'profile') {
- $profile_photo = $photo->value;
- continue;
+ }
+ if(isset($entry->photos)) {
+ foreach($entry->photos as $photo) {
+ if($photo->type == 'profile') {
+ $profile_photo = $photo->value;
+ continue;
+ }
}
}