Merge user feeds & followers #118

Merged
aheathershaw merged 16 commits from feature/111-user-activity-feeds into master 2018-11-19 19:08:50 +00:00
2 changed files with 11 additions and 1 deletions
Showing only changes of commit 42a1e4b770 - Show all commits

View File

@ -22,6 +22,11 @@ class UserController extends Controller
{ {
public function activityFeed() public function activityFeed()
{ {
if (!UserConfig::get('social_user_feeds'))
{
return redirect(route('home'));
}
return Theme::render('gallery.user_activity_feed', [ return Theme::render('gallery.user_activity_feed', [
'user' => $this->getUser() 'user' => $this->getUser()
]); ]);
@ -29,6 +34,11 @@ class UserController extends Controller
public function activityFeedJson() public function activityFeedJson()
{ {
if (!UserConfig::get('social_user_feeds'))
{
return response()->json(['message' => 'Activity feeds not enabled']);
}
$user = $this->getUser(); $user = $this->getUser();
$result = []; $result = [];

View File

@ -6,7 +6,7 @@
<div class="collapse navbar-collapse" id="navbar-content"> <div class="collapse navbar-collapse" id="navbar-content">
<ul class="navbar-nav mr-auto"> <ul class="navbar-nav mr-auto">
@if (!Auth::guest()) @if (!Auth::guest() && UserConfig::get('social_user_feeds'))
<li class="nav-item"> <li class="nav-item">
<a class="nav-link" href="{{ route('userActivityFeed') }}"> <a class="nav-link" href="{{ route('userActivityFeed') }}">
<i class="fa fa-rss"></i> @lang('navigation.navbar.activity_feed') <i class="fa fa-rss"></i> @lang('navigation.navbar.activity_feed')