X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=dwpost%2Fdwpost.php;h=56e04f783c2be41e7925a903e093d0cddf58f1b6;hb=2d4ecd5ccf25c844502e2cadbf60f3cad5b33ba7;hp=975d703ed822202ba56b09563bdb7f04b86f3cf2;hpb=bbaf463a204f84d0ac05336925abf99ae3583b8e;p=friendica-addons.git
diff --git a/dwpost/dwpost.php b/dwpost/dwpost.php
index 975d703e..56e04f78 100644
--- a/dwpost/dwpost.php
+++ b/dwpost/dwpost.php
@@ -11,12 +11,12 @@
use Friendica\App;
use Friendica\Content\Text\BBCode;
use Friendica\Core\Hook;
-use Friendica\Core\L10n;
use Friendica\Core\Logger;
use Friendica\Database\DBA;
use Friendica\DI;
+use Friendica\Model\Post;
+use Friendica\Model\Tag;
use Friendica\Util\DateTimeFormat;
-use Friendica\Util\Network;
use Friendica\Util\XML;
function dwpost_install()
@@ -28,15 +28,6 @@ function dwpost_install()
Hook::register('connector_settings_post', 'addon/dwpost/dwpost.php', 'dwpost_settings_post');
}
-function dwpost_uninstall()
-{
- Hook::unregister('post_local', 'addon/dwpost/dwpost.php', 'dwpost_post_local');
- Hook::unregister('notifier_normal', 'addon/dwpost/dwpost.php', 'dwpost_send');
- Hook::unregister('jot_networks', 'addon/dwpost/dwpost.php', 'dwpost_jot_nets');
- Hook::unregister('connector_settings', 'addon/dwpost/dwpost.php', 'dwpost_settings');
- Hook::unregister('connector_settings_post', 'addon/dwpost/dwpost.php', 'dwpost_settings_post');
-}
-
function dwpost_jot_nets(App $a, array &$jotnets_fields)
{
if (!local_user()) {
@@ -48,7 +39,7 @@ function dwpost_jot_nets(App $a, array &$jotnets_fields)
'type' => 'checkbox',
'field' => [
'dwpost_enable',
- L10n::t('Post to Dreamwidth'),
+ DI::l10n()->t('Post to Dreamwidth'),
DI::pConfig()->get(local_user(), 'dwpost', 'post_by_default')
]
];
@@ -79,35 +70,35 @@ function dwpost_settings(App $a, &$s)
/* Add some HTML to the existing form */
$s .= '';
- $s .= ''. L10n::t("Dreamwidth Export").'
';
+ $s .= ''. DI::l10n()->t("Dreamwidth Export").'
';
$s .= '';
$s .= '