X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=nsfw%2Fnsfw.php;h=9f81b29d8333557f669a26dc735a9a23c711616b;hb=af10b60e97b94ba5e8bf60195038c51433966e08;hp=4369df408a848de08ba4a47e0981897eb2b15e26;hpb=febc835a2d90509a54a41dca07dba1d8e3ed6d07;p=friendica-addons.git
diff --git a/nsfw/nsfw.php b/nsfw/nsfw.php
index 4369df40..9f81b29d 100644
--- a/nsfw/nsfw.php
+++ b/nsfw/nsfw.php
@@ -8,8 +8,6 @@
*
*/
use Friendica\Core\Hook;
-use Friendica\Core\L10n;
-use Friendica\Core\PConfig;
use Friendica\DI;
function nsfw_install()
@@ -19,14 +17,6 @@ function nsfw_install()
Hook::register('addon_settings_post', 'addon/nsfw/nsfw.php', 'nsfw_addon_settings_post');
}
-function nsfw_uninstall()
-{
- Hook::unregister('prepare_body_content_filter', 'addon/nsfw/nsfw.php', 'nsfw_prepare_body_content_filter');
- Hook::unregister('prepare_body', 'addon/nsfw/nsfw.php', 'nsfw_prepare_body');
- Hook::unregister('addon_settings', 'addon/nsfw/nsfw.php', 'nsfw_addon_settings');
- Hook::unregister('addon_settings_post', 'addon/nsfw/nsfw.php', 'nsfw_addon_settings_post');
-}
-
// This function isn't perfect and isn't trying to preserve the html structure - it's just a
// quick and dirty filter to pull out embedded photo blobs because 'nsfw' seems to come up
// inside them quite often. We don't need anything fancy, just pull out the data blob so we can
@@ -75,24 +65,24 @@ function nsfw_addon_settings(&$a, &$s)
}
$s .= '';
- $s .= '
' . L10n::t('Content Filter (NSFW and more)') . '
';
+ $s .= '
' . DI::l10n()->t('Content Filter (NSFW and more)') . '
';
$s .= '';
$s .= '
';
$s .= '';
- $s .= '
' . L10n::t('Content Filter (NSFW and more)') . '
';
+ $s .= '
' . DI::l10n()->t('Content Filter (NSFW and more)') . '
';
$s .= '';
$s .= '
';
- $s .= '
' . L10n::t('This addon searches for specified words/text in posts and collapses them. It can be used to filter content tagged with for instance #NSFW that may be deemed inappropriate at certain times or places, such as being at work. It is also useful for hiding irrelevant or annoying content from direct view.') . '
';
- $s .= '';
+ $s .= '
' . DI::l10n()->t('This addon searches for specified words/text in posts and collapses them. It can be used to filter content tagged with for instance #NSFW that may be deemed inappropriate at certain times or places, such as being at work. It is also useful for hiding irrelevant or annoying content from direct view.') . '