aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module/Dreport.php
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2021-09-04 08:18:41 +0000
committerMario <mario@mariovavti.com>2021-09-04 08:18:41 +0000
commit529824d010cf88c409d5ce894b72060caccae580 (patch)
tree034260ebb84edef72f87a450ab3915e4726e3368 /Zotlabs/Module/Dreport.php
parentc47e21f3a74e4290bd206c1f7edb377e809d7e42 (diff)
downloadvolse-hubzilla-529824d010cf88c409d5ce894b72060caccae580.tar.gz
volse-hubzilla-529824d010cf88c409d5ce894b72060caccae580.tar.bz2
volse-hubzilla-529824d010cf88c409d5ce894b72060caccae580.zip
more unpack_link_id()
Diffstat (limited to 'Zotlabs/Module/Dreport.php')
-rw-r--r--Zotlabs/Module/Dreport.php18
1 files changed, 3 insertions, 15 deletions
diff --git a/Zotlabs/Module/Dreport.php b/Zotlabs/Module/Dreport.php
index 8906a4f81..42f337b76 100644
--- a/Zotlabs/Module/Dreport.php
+++ b/Zotlabs/Module/Dreport.php
@@ -12,24 +12,12 @@ class Dreport extends \Zotlabs\Web\Controller {
}
$table = 'item';
-
$channel = \App::get_channel();
+ $mid = ((argc() > 1) ? unpack_link_id(argv(1)) : '');
- $mid = ((argc() > 1) ? argv(1) : '');
- $encoded_mid = '';
-
- if(strpos($mid,'b64.') === 0) {
- $encoded_mid = $mid;
- $mid = @base64url_decode(substr($mid,4));
- }
if($mid === 'push') {
$table = 'push';
- $mid = ((argc() > 2) ? argv(2) : '');
-
- if(strpos($mid,'b64.') === 0) {
- $encoded_mid = $mid;
- $mid = @base64url_decode(substr($mid,4));
- }
+ $mid = ((argc() > 2) ? unpack_link_id(argv(2)) : '');
if($mid) {
$i = q("select id from item where mid = '%s' and uid = %d and ( author_xchan = '%s' or ( owner_xchan = '%s' and item_wall = 1 )) ",
@@ -43,7 +31,7 @@ class Dreport extends \Zotlabs\Web\Controller {
}
}
sleep(3);
- goaway(z_root() . '/dreport/' . (($encoded_mid) ? $encoded_mid : $mid));
+ goaway(z_root() . '/dreport/' . gen_link_id($mid));
}
if(! $mid) {