$comment = App\Comment::find(1);
$commentable = $comment->commentable;
commentable can be App\Video or App\Post. Is it possible to get exact type such as $comment->video or $comment->post
Please sign in or create an account to participate in this conversation.
There's no shortage of content at Laracasts. In fact, you could watch nonstop
for days upon days, and still not see everything!