src/Widgets/NotificationSender/Controller/NotificationController.php
protected function getRecipient()
    {
        if (Input::get('test')) {
            return user();
        }
        $route = app('router')->getRoutes()->match(app('request')->create(url()->previous()));
        return (in_array('users', $route->parameterNames()) && $uid   = $route->parameter('users')) ? user()->newQuery()->findOrFail($uid) : user();
    }
protected function getRecipient()
    {
        if (Input::get('test')) {
            return user();
        }
        $route = app('router')->getRoutes()->match(app('request')->create(url()->previous()));
        return (in_array('users', $route->parameterNames()) && $uid   = $route->parameter('users')) ? user()->newQuery()->findOrFail($uid) : user();
    }
protected function getRecipient ( ) { if ( Input :: get ( 'test' ) ) { return user ( ) ; } $ route = app ( 'router' ) -> getRoutes ( ) -> match ( app ( 'request' ) -> create ( url ( ) -> previous ( ) ) ) ; return ( in_array ( 'users' , $ route -> parameterNames ( ) ) && $ uid = $ route -> parameter ( 'users' ) ) ? user ( ) -> newQuery ( ) -> findOrFail ( $ uid ) : user ( ) ; }
Gets recipient for notification

@return \Illuminate\Database\Eloquent\Model
Gets recipient for notification