use Friendica\Model\Item;
use Friendica\Util\DateTimeFormat;
use Friendica\Util\Temporal;
+use Friendica\Util\Proxy as ProxyUtils;
use Friendica\Util\XML;
-require_once 'mod/proxy.php';
require_once 'include/enotify.php';
/**
if (local_user()) {
// Different login session than the page that is calling us.
- if (intval($_GET['uid']) && intval($_GET['uid']) != local_user()) {
+ if (!empty($_GET['uid']) && intval($_GET['uid']) != local_user()) {
$data = ['result' => ['invalid' => 1]];
if ($format == 'json') {
if (DBA::isResult($notifs)) {
// Are the nofications called from the regular process or via the friendica app?
- $regularnotifications = (intval($_GET['uid']) && intval($_GET['_']));
+ $regularnotifications = (!empty($_GET['uid']) && !empty($_GET['_']));
foreach ($notifs as $notif) {
if ($a->is_friendica_app() || !$regularnotifications) {
$contact = Contact::getDetailsByURL($notif['url']);
if (isset($contact['micro'])) {
- $notif['photo'] = proxy_url($contact['micro'], false, PROXY_SIZE_MICRO);
+ $notif['photo'] = ProxyUtils::proxifyUrl($contact['micro'], false, ProxyUtils::SIZE_MICRO);
} else {
- $notif['photo'] = proxy_url($notif['photo'], false, PROXY_SIZE_MICRO);
+ $notif['photo'] = ProxyUtils::proxifyUrl($notif['photo'], false, ProxyUtils::SIZE_MICRO);
}
$local_time = DateTimeFormat::local($notif['date']);