mirror of
https://github.com/ad-aures/castopod.git
synced 2026-04-16 04:57:46 +02:00
refactor(auth): replace myth/auth with codeigniter/shield + define new roles
closes #222
This commit is contained in:
parent
c760acc79d
commit
c1287cbe6c
213 changed files with 3366 additions and 3204 deletions
|
|
@ -79,7 +79,7 @@ class EpisodeCommentController extends BaseController
|
|||
public function view(): string
|
||||
{
|
||||
// Prevent analytics hit when authenticated
|
||||
if (! can_user_interact()) {
|
||||
if (! auth()->loggedIn()) {
|
||||
$this->registerPodcastWebpageHit($this->podcast->id);
|
||||
}
|
||||
|
||||
|
|
@ -91,7 +91,8 @@ class EpisodeCommentController extends BaseController
|
|||
"comment#{$this->comment->id}",
|
||||
service('request')
|
||||
->getLocale(),
|
||||
can_user_interact() ? 'authenticated' : null,
|
||||
auth()
|
||||
->loggedIn() ? 'authenticated' : null,
|
||||
]),
|
||||
);
|
||||
|
||||
|
|
@ -105,7 +106,7 @@ class EpisodeCommentController extends BaseController
|
|||
];
|
||||
|
||||
// if user is logged in then send to the authenticated activity view
|
||||
if (can_user_interact()) {
|
||||
if (auth()->loggedIn()) {
|
||||
helper('form');
|
||||
return view('episode/comment', $data);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue