aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2013-02-13 02:40:06 -0800
committerfriendica <info@friendica.com>2013-02-13 02:40:06 -0800
commitc769c2e79f4209bb745e51733aba8668cd1f9ede (patch)
tree9d55baa6a61250dd11e8a9c2abda98b83c84de3d
parent942adadec63805e9f6dbed63d7f8a4b69a597e91 (diff)
downloadvolse-hubzilla-c769c2e79f4209bb745e51733aba8668cd1f9ede.tar.gz
volse-hubzilla-c769c2e79f4209bb745e51733aba8668cd1f9ede.tar.bz2
volse-hubzilla-c769c2e79f4209bb745e51733aba8668cd1f9ede.zip
some more rmagic fixes discovered during testing
-rw-r--r--boot.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/boot.php b/boot.php
index 363fa2e4f..4c9ee68ce 100644
--- a/boot.php
+++ b/boot.php
@@ -1974,7 +1974,7 @@ function get_my_address() {
function zid_init(&$a) {
$tmp_str = get_my_address();
- if($tmp_str && strpos($tmp_str,'@')) {
+ if(validate_email($tmp_str)) {
proc_run('php','include/gprobe.php',$tmp_str);
$arr = array('zid' => $tmp_str, 'url' => $a->cmd);
call_hooks('zid_init',$arr);
@@ -1983,9 +1983,9 @@ function zid_init(&$a) {
dbesc($tmp_str)
);
// try to avoid recursion - but send them home to do a proper magic auth
- $dest = $a->query_string;
+ $dest = '/' . $a->query_string;
$dest = str_replace(array('?zid=','&zid='),array('?rzid=','&rzid='),$dest);
- if($r && ($r[0]['hubloc_url'] != z_root()) && (! strstr($dest,'/magic'))) {
+ if($r && ($r[0]['hubloc_url'] != z_root()) && (! strstr($dest,'/magic')) && (! strstr($dest,'/rmagic'))) {
goaway($r[0]['hubloc_url'] . '/magic' . '?f=&dest=' . z_root() . $dest);
}
}