mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-10 00:34:50 +00:00
Update nav and Bouncer
This commit is contained in:
parent
d1880ee6b8
commit
053b30bca0
2 changed files with 60 additions and 42 deletions
|
@ -10,6 +10,7 @@ use App\Services\NotificationService;
|
||||||
use App\Services\StatusService;
|
use App\Services\StatusService;
|
||||||
use App\Jobs\ReportPipeline\AutospamNotifyAdminViaEmail;
|
use App\Jobs\ReportPipeline\AutospamNotifyAdminViaEmail;
|
||||||
use App\Notification;
|
use App\Notification;
|
||||||
|
use App\Services\AutospamService;
|
||||||
|
|
||||||
class Bouncer {
|
class Bouncer {
|
||||||
|
|
||||||
|
@ -65,6 +66,12 @@ class Bouncer {
|
||||||
return (new self)->handle($status);
|
return (new self)->handle($status);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(AutospamService::active()) {
|
||||||
|
if(AutospamService::check($status->caption)) {
|
||||||
|
return (new self)->handle($status);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$recentKey = 'pf:bouncer_v0:recent_by_pid:' . $status->profile_id;
|
$recentKey = 'pf:bouncer_v0:recent_by_pid:' . $status->profile_id;
|
||||||
$recentTtl = now()->addHours(28);
|
$recentTtl = now()->addHours(28);
|
||||||
|
|
||||||
|
|
|
@ -15,6 +15,13 @@
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link {{request()->is('*autospam*')?'active':''}}" href="{{route('admin.autospam')}}">
|
||||||
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
<span class="nav-link-text">Autospam <span class="badge badge-primary ml-1">NEW</span></span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link {{request()->is('*messages*')?'active':''}}" href="{{route('admin.messages')}}">
|
<a class="nav-link {{request()->is('*messages*')?'active':''}}" href="{{route('admin.messages')}}">
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
@ -36,13 +43,6 @@
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li class="nav-item">
|
|
||||||
<a class="nav-link {{request()->is('*stories*')?'active':''}}" href="{{route('admin.stories')}}">
|
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
|
||||||
<span class="nav-link-text">Stories <span class="badge badge-primary ml-1">NEW</span></span>
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
|
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link {{request()->is('*users*')?'active':''}}" href="{{route('admin.users')}}">
|
<a class="nav-link {{request()->is('*users*')?'active':''}}" href="{{route('admin.users')}}">
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
@ -60,22 +60,7 @@
|
||||||
|
|
||||||
<hr class="my-3">
|
<hr class="my-3">
|
||||||
|
|
||||||
<ul class="navbar-nav mb-md-3">
|
<ul class="navbar-nav">
|
||||||
|
|
||||||
<li class="nav-item">
|
|
||||||
<a class="nav-link {{request()->is('*directory*')?'active':''}}" href="{{route('admin.directory')}}">
|
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
|
||||||
<span class="nav-link-text">Directory <span class="badge badge-primary ml-1">NEW</span></span>
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
|
|
||||||
<li class="nav-item">
|
|
||||||
<a class="nav-link {{request()->is('*apps*')?'active':''}}" href="{{route('admin.apps')}}">
|
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
|
||||||
<span class="nav-link-text">Apps</span>
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
|
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link {{request()->is('*custom-emoji*')?'active':''}}" href="{{route('admin.custom-emoji')}}">
|
<a class="nav-link {{request()->is('*custom-emoji*')?'active':''}}" href="{{route('admin.custom-emoji')}}">
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
@ -83,13 +68,6 @@
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li class="nav-item">
|
|
||||||
<a class="nav-link {{request()->is('*diagnostics*')?'active':''}}" href="{{route('admin.diagnostics')}}">
|
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
|
||||||
<span class="nav-link-text">Diagnostics <span class="badge badge-primary ml-1">NEW</span></span>
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
|
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link {{request()->is('*hashtags*')?'active':''}}" href="{{route('admin.hashtags')}}">
|
<a class="nav-link {{request()->is('*hashtags*')?'active':''}}" href="{{route('admin.hashtags')}}">
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
@ -97,13 +75,6 @@
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li class="nav-item">
|
|
||||||
<a class="nav-link" href="/horizon">
|
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
|
||||||
<span class="nav-link-text">Horizon</span>
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
|
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link {{request()->is('*instances*')?'active':''}}" href="{{route('admin.instances')}}">
|
<a class="nav-link {{request()->is('*instances*')?'active':''}}" href="{{route('admin.instances')}}">
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
@ -119,16 +90,57 @@
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link {{request()->is('*site-news*')?'active':''}}" href="/i/admin/site-news">
|
<a class="nav-link {{request()->is('*profiles*')?'active':''}}" href="/i/admin/profiles">
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
<span class="nav-link-text">Newsroom</span>
|
<span class="nav-link-text">Profiles</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link {{request()->is('*profiles*')?'active':''}}" href="/i/admin/profiles">
|
<a class="nav-link {{request()->is('*stories*')?'active':''}}" href="{{route('admin.stories')}}">
|
||||||
<i class="ni ni-bold-right text-primary"></i>
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
<span class="nav-link-text">Profiles</span>
|
<span class="nav-link-text">Stories <span class="badge badge-primary ml-1">NEW</span></span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<hr class="my-3">
|
||||||
|
|
||||||
|
<ul class="navbar-nav mb-md-3">
|
||||||
|
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link {{request()->is('*apps*')?'active':''}}" href="{{route('admin.apps')}}">
|
||||||
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
<span class="nav-link-text">Apps</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link {{request()->is('*diagnostics*')?'active':''}}" href="{{route('admin.diagnostics')}}">
|
||||||
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
<span class="nav-link-text">Diagnostics <span class="badge badge-primary ml-1">NEW</span></span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link {{request()->is('*directory*')?'active':''}}" href="{{route('admin.directory')}}">
|
||||||
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
<span class="nav-link-text">Directory <span class="badge badge-primary ml-1">NEW</span></span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="/horizon">
|
||||||
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
<span class="nav-link-text">Horizon</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link {{request()->is('*site-news*')?'active':''}}" href="/i/admin/site-news">
|
||||||
|
<i class="ni ni-bold-right text-primary"></i>
|
||||||
|
<span class="nav-link-text">Newsroom</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
@ -152,7 +164,6 @@
|
||||||
<span class="nav-link-text">System</span>
|
<span class="nav-link-text">System</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in a new issue