aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2021-09-07 10:21:02 +0000
committerMario <mario@mariovavti.com>2021-09-07 10:21:02 +0000
commitddbc55d16611d3e7aa0c5af88072a004ff03c26d (patch)
treeaabdf9a1361e3af2043fecd4c9a05b607086c443 /Zotlabs/Module
parent1d3a59e0cdbbea476029a6b0c3b7c0045144fa31 (diff)
downloadvolse-hubzilla-ddbc55d16611d3e7aa0c5af88072a004ff03c26d.tar.gz
volse-hubzilla-ddbc55d16611d3e7aa0c5af88072a004ff03c26d.tar.bz2
volse-hubzilla-ddbc55d16611d3e7aa0c5af88072a004ff03c26d.zip
fix mod display regressions
Diffstat (limited to 'Zotlabs/Module')
-rw-r--r--Zotlabs/Module/Display.php17
1 files changed, 10 insertions, 7 deletions
diff --git a/Zotlabs/Module/Display.php b/Zotlabs/Module/Display.php
index 5ffb1346c..02a79f854 100644
--- a/Zotlabs/Module/Display.php
+++ b/Zotlabs/Module/Display.php
@@ -37,7 +37,15 @@ class Display extends \Zotlabs\Web\Controller {
}
if($_REQUEST['mid']) {
- $item_hash = unpack_link_id($_REQUEST['mid']);
+ $item_hash = $_REQUEST['mid'];
+ }
+
+ $item_hash = unpack_link_id($item_hash);
+
+ if ($item_hash === false) {
+ App::$error = 400;
+ notice(t('Malformed message id.') . EOL);
+ return;
}
if(!$item_hash) {
@@ -95,11 +103,6 @@ class Display extends \Zotlabs\Web\Controller {
$target_item = null;
- if ($item_hash === false) {
- notice(t('Malformed message id.') . EOL);
- return;
- }
-
$r = q("select id, uid, mid, parent, parent_mid, thr_parent, verb, item_type, item_deleted, author_xchan, item_blocked from item where mid = '%s' limit 1",
dbesc($item_hash)
);
@@ -374,7 +377,7 @@ class Display extends \Zotlabs\Web\Controller {
'$feed_updated' => xmlify(datetime_convert('UTC', 'UTC', 'now', ATOM_TIME)),
'$author' => '',
'$owner' => '',
- '$profile_page' => xmlify(z_root() . '/display/' . $target_item['mid']),
+ '$profile_page' => xmlify(z_root() . '/display/' . gen_link_id($target_item['mid'])),
));
$x = [ 'xml' => $atom, 'channel' => $channel, 'observer_hash' => $observer_hash, 'params' => $params ];