streams/Zotlabs/Widget/Website_portation_tools.php

29 lines
578 B
PHP
Raw Normal View History

<?php
namespace Zotlabs\Widget;
2021-12-02 22:33:36 +00:00
use App;
2021-12-02 23:02:31 +00:00
class Website_portation_tools
{
2021-12-02 23:02:31 +00:00
public function widget($arr)
{
2021-12-02 23:02:31 +00:00
// mod menu doesn't load a profile. For any modules which load a profile, check it.
// otherwise local_channel() is sufficient for permissions.
2021-12-03 03:01:39 +00:00
if (App::$profile['profile_uid']) {
if ((App::$profile['profile_uid'] != local_channel()) && (!App::$is_sys)) {
2021-12-02 23:02:31 +00:00
return '';
2021-12-03 03:01:39 +00:00
}
}
2021-12-03 03:01:39 +00:00
if (!local_channel()) {
2021-12-02 23:02:31 +00:00
return '';
2021-12-03 03:01:39 +00:00
}
2021-12-02 23:02:31 +00:00
return website_portation_tools();
}
}