aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module/Poke.php
diff options
context:
space:
mode:
authorMario Vavti <mario@mariovavti.com>2018-09-15 11:09:16 +0200
committerMario Vavti <mario@mariovavti.com>2018-09-15 11:09:16 +0200
commit791ff25d52c7f7e95758f1218a1621012b15be7c (patch)
tree2707af3ca9580b2357c8160e232b80c8a00746ae /Zotlabs/Module/Poke.php
parent299eb469f8d4d674c49e41162d28f237c0d7294f (diff)
downloadvolse-hubzilla-791ff25d52c7f7e95758f1218a1621012b15be7c.tar.gz
volse-hubzilla-791ff25d52c7f7e95758f1218a1621012b15be7c.tar.bz2
volse-hubzilla-791ff25d52c7f7e95758f1218a1621012b15be7c.zip
appify poke
Diffstat (limited to 'Zotlabs/Module/Poke.php')
-rw-r--r--Zotlabs/Module/Poke.php21
1 files changed, 19 insertions, 2 deletions
diff --git a/Zotlabs/Module/Poke.php b/Zotlabs/Module/Poke.php
index d13ec5ced..46dcf6dd3 100644
--- a/Zotlabs/Module/Poke.php
+++ b/Zotlabs/Module/Poke.php
@@ -1,6 +1,10 @@
<?php
namespace Zotlabs\Module; /** @file */
+use App;
+use Zotlabs\Lib\Apps;
+use Zotlabs\Web\Controller;
+
/**
*
* Poke, prod, finger, or otherwise do unspeakable things to somebody - who must be a connection in your address book
@@ -18,15 +22,19 @@ namespace Zotlabs\Module; /** @file */
require_once('include/items.php');
-class Poke extends \Zotlabs\Web\Controller {
+class Poke extends Controller {
function init() {
if(! local_channel())
return;
+
+ if(! Apps::system_app_installed(local_channel(), 'Poke')) {
+ return;
+ }
$uid = local_channel();
- $channel = \App::get_channel();
+ $channel = App::get_channel();
$verb = notags(trim($_REQUEST['verb']));
@@ -150,6 +158,15 @@ class Poke extends \Zotlabs\Web\Controller {
return;
}
+ if(! Apps::system_app_installed(local_channel(), 'Poke')) {
+ //Do not display any associated widgets at this point
+ App::$pdl = '';
+
+ $o = '<b>Poke App (Not Installed):</b><br>';
+ $o .= t('Poke somebody in your addressbook');
+ return $o;
+ }
+
nav_set_selected('Poke');
$name = '';