forked from friendica/friendica-addons
Fixed wrong type-hint + "imported" class
This commit is contained in:
parent
43c0e689f9
commit
93267b5b83
4 changed files with 10 additions and 8 deletions
|
@ -67,7 +67,7 @@ function mailstream_module()
|
||||||
/**
|
/**
|
||||||
* Adds an item in "addon features" in the admin menu of the site
|
* Adds an item in "addon features" in the admin menu of the site
|
||||||
*
|
*
|
||||||
* @param Friendica\App $a App object (unused)
|
* @param App $a App object (unused)
|
||||||
* @param string $o HTML form data
|
* @param string $o HTML form data
|
||||||
*/
|
*/
|
||||||
function mailstream_addon_admin(App $a, &$o)
|
function mailstream_addon_admin(App $a, &$o)
|
||||||
|
@ -138,7 +138,7 @@ function mailstream_send_hook(App $a, $data)
|
||||||
* mailstream is enabled and the necessary data is available, forks a
|
* mailstream is enabled and the necessary data is available, forks a
|
||||||
* workerqueue item to send the email.
|
* workerqueue item to send the email.
|
||||||
*
|
*
|
||||||
* @param Friendica\App $a App object (unused)
|
* @param App $a App object (unused)
|
||||||
* @param array $item content of the item (may or may not already be stored in the item table)
|
* @param array $item content of the item (may or may not already be stored in the item table)
|
||||||
*/
|
*/
|
||||||
function mailstream_post_hook(App $a, &$item)
|
function mailstream_post_hook(App $a, &$item)
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
* Status: Unsupported
|
* Status: Unsupported
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
use Friendica\App;
|
||||||
use Friendica\Core\Hook;
|
use Friendica\Core\Hook;
|
||||||
use Friendica\DI;
|
use Friendica\DI;
|
||||||
use Friendica\Util\DateTimeFormat;
|
use Friendica\Util\DateTimeFormat;
|
||||||
|
@ -16,7 +17,7 @@ function membersince_install()
|
||||||
Hook::register('profile_advanced', 'addon/membersince/membersince.php', 'membersince_display');
|
Hook::register('profile_advanced', 'addon/membersince/membersince.php', 'membersince_display');
|
||||||
}
|
}
|
||||||
|
|
||||||
function membersince_display(Friendica\App $a, array &$b)
|
function membersince_display(App $a, array &$b)
|
||||||
{
|
{
|
||||||
if ($a->getCurrentTheme() == 'frio') {
|
if ($a->getCurrentTheme() == 'frio') {
|
||||||
// Works in Frio.
|
// Works in Frio.
|
||||||
|
|
|
@ -44,10 +44,10 @@ function rendertime_addon_admin_post(App $a)
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param Friendica\App $a
|
* @param App $a
|
||||||
* @param string $o
|
* @param string $o
|
||||||
*/
|
*/
|
||||||
function rendertime_page_end(Friendica\App $a, &$o)
|
function rendertime_page_end(App $a, &$o)
|
||||||
{
|
{
|
||||||
|
|
||||||
$profiler = DI::profiler();
|
$profiler = DI::profiler();
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
* Maintainer: Hypolite Petovan <https://friendica.mrpetovan.com/profile/hypolite>
|
* Maintainer: Hypolite Petovan <https://friendica.mrpetovan.com/profile/hypolite>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
use Friendica\App;
|
||||||
use Friendica\Core\Hook;
|
use Friendica\Core\Hook;
|
||||||
use Friendica\DI;
|
use Friendica\DI;
|
||||||
|
|
||||||
|
@ -16,7 +17,7 @@ function smileybutton_install()
|
||||||
Hook::register('jot_tool', 'addon/smileybutton/smileybutton.php', 'smileybutton_jot_tool');
|
Hook::register('jot_tool', 'addon/smileybutton/smileybutton.php', 'smileybutton_jot_tool');
|
||||||
}
|
}
|
||||||
|
|
||||||
function smileybutton_jot_tool(Friendica\App $a, array &$b)
|
function smileybutton_jot_tool(App $a, string &$body)
|
||||||
{
|
{
|
||||||
// Disable if theme is quattro
|
// Disable if theme is quattro
|
||||||
// TODO add style for quattro
|
// TODO add style for quattro
|
||||||
|
@ -113,7 +114,7 @@ function smileybutton_jot_tool(Friendica\App $a, array &$b)
|
||||||
$image_url = DI::baseUrl()->get() . '/' . $image;
|
$image_url = DI::baseUrl()->get() . '/' . $image;
|
||||||
|
|
||||||
//Add the hmtl and script to the page
|
//Add the hmtl and script to the page
|
||||||
$b = <<< EOT
|
$body = <<< EOT
|
||||||
<div id="profile-smiley-wrapper">
|
<div id="profile-smiley-wrapper">
|
||||||
<button type="button" class="btn btn-link smiley_button" onclick="toggle_smileybutton()"><img src="$image_url" alt="smiley"></button>
|
<button type="button" class="btn btn-link smiley_button" onclick="toggle_smileybutton()"><img src="$image_url" alt="smiley"></button>
|
||||||
<div id="smileybutton">
|
<div id="smileybutton">
|
||||||
|
|
Loading…
Reference in a new issue