Whoops! There was an error.
Symfony \ Component \ Debug \ Exception \ FatalThrowableError (E_ERROR)
Call to a member function translate() on null Symfony\Component\Debug\Exception\FatalThrowableError thrown with message "Call to a member function translate() on null" Stacktrace: #0 Symfony\Component\Debug\Exception\FatalThrowableError in /home/coindealing/public_html/app/Http/Controllers/Web/PagesController.php:25
Application frames (1) All frames (1)
0
Symfony
\
Component
\
Debug
\
Exception
\
FatalThrowableError
/
app
/
Http
/
Controllers
/
Web
/
PagesController.php
25
/
home
/
coindealing
/
public_html
/
app
/
Http
/
Controllers
/
Web
/
PagesController.php
use TCG\Voyager\Models\Page;
class PagesController extends Controller
{
    public function index()
    {
       
         $slug = Request::segment(3);
 
        $language = LaravelLocalization::getCurrentLocale();
        $page = Page::withTranslation($language)->where('slug', '=', $slug)
                                        ->where('status', '=', 'ACTIVE')
                    ->first();
        if(!isset($page->title)) { //show English content as a default
            $page = Page::withTranslation($language)->where('slug', '=', $slug)
                    
                    ->where('status', '=', 'ACTIVE')
                    ->first();
        }    
        
        $page = $page->translate($language, 'en');
         
        return view(getCurrentTemplate() . '.pages.static.page', ['data' => $page]);
    }
    
 
}
Arguments
  1. "Call to a member function translate() on null"
    

Environment & details:

empty
empty
empty
empty
empty
Key Value
TZ
"UTC"
REDIRECT_REDIRECT_UNIQUE_ID
"YAVfAqwjcCYtbTxGCA5nqQAAAAY"
REDIRECT_REDIRECT_SCRIPT_URL
"/en/page/fxcm"
REDIRECT_REDIRECT_SCRIPT_URI
"https://coindealing.org/en/page/fxcm"
REDIRECT_REDIRECT_HTTPS
"on"
REDIRECT_REDIRECT_SSL_TLS_SNI
"coindealing.org"
REDIRECT_REDIRECT_STATUS
"200"
REDIRECT_UNIQUE_ID
"YAVfAqwjcCYtbTxGCA5nqQAAAAY"
REDIRECT_SCRIPT_URL
"/en/page/fxcm"
REDIRECT_SCRIPT_URI
"https://coindealing.org/en/page/fxcm"
REDIRECT_HTTPS
"on"
REDIRECT_SSL_TLS_SNI
"coindealing.org"
REDIRECT_HANDLER
"application/x-httpd-ea-php72"
REDIRECT_STATUS
"200"
UNIQUE_ID
"YAVfAqwjcCYtbTxGCA5nqQAAAAY"
SCRIPT_URL
"/en/page/fxcm"
SCRIPT_URI
"https://coindealing.org/en/page/fxcm"
HTTPS
"on"
SSL_TLS_SNI
"coindealing.org"
HTTP_USER_AGENT
"CCBot/2.0 (https://commoncrawl.org/faq/)"
HTTP_ACCEPT
"text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"
HTTP_ACCEPT_LANGUAGE
"en-US,en;q=0.5"
HTTP_ACCEPT_ENCODING
"br,gzip"
HTTP_HOST
"coindealing.org"
HTTP_CONNECTION
"Keep-Alive"
HTTP_X_HTTPS
"1"
PATH
"/usr/local/jdk/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/usr/local/bin:/usr/X11R6/bin:/root/bin:/opt/bin"
SERVER_SIGNATURE
""
SERVER_SOFTWARE
"Apache"
SERVER_NAME
"coindealing.org"
SERVER_ADDR
"212.24.97.252"
SERVER_PORT
"443"
REMOTE_ADDR
"3.238.70.175"
DOCUMENT_ROOT
"/home/coindealing/public_html"
REQUEST_SCHEME
"https"
CONTEXT_PREFIX
"/cgi-sys"
CONTEXT_DOCUMENT_ROOT
"/usr/local/cpanel/cgi-sys/"
SERVER_ADMIN
"webmaster@coindealing.org"
SCRIPT_FILENAME
"/home/coindealing/public_html/index.php"
REMOTE_PORT
"56098"
REDIRECT_URL
"/index.php"
GATEWAY_INTERFACE
"CGI/1.1"
SERVER_PROTOCOL
"HTTP/1.1"
REQUEST_METHOD
"GET"
QUERY_STRING
""
REQUEST_URI
"/en/page/fxcm"
SCRIPT_NAME
"/index.php"
ORIG_SCRIPT_FILENAME
"/usr/local/cpanel/cgi-sys/ea-php72"
ORIG_PATH_INFO
"/index.php"
ORIG_PATH_TRANSLATED
"/home/coindealing/public_html/index.php"
ORIG_SCRIPT_NAME
"/cgi-sys/ea-php72"
PHP_SELF
"/index.php"
REQUEST_TIME_FLOAT
1610964738.5497
REQUEST_TIME
1610964738
argv
[]
argc
0
APP_NAME
"Laravel"
APP_ENV
"development"
APP_KEY
"base64:pAfDt2B0Q/9QFeHjP8dI4N4pvUvXL2xIebj0G1Fmxho="
APP_DEBUG
"true"
APP_LOG_LEVEL
"debug"
APP_URL
"https://coindealing.org"
SITE_URL
"https://coindealing.org/"
DB_CONNECTION
"mysql"
DB_HOST
"localhost"
DB_PORT
"3306"
DB_DATABASE
"coindeal_mainDB"
DB_USERNAME
"coindeal_mainDBU"
DB_PASSWORD
"HiDoX;6mqx~p"
MAIL_EMAIL_ADDRESS
"support@coindealing.org"
MAIL_FROM_ADDRESS
"support@coindealing.org"
FB_CLIENT_ID
""
FB_SECRET_ID
""
FB_REDIRECT_URL
""
TW_CLIENT_ID
""
TW_SECRET_ID
""
TW_REDIRECT_URL
""
TWITTER_CONSUMER_KEY
""
TWITTER_CONSUMER_SECRET
""
TWITTER_ACCESS_TOKEN
""
TWITTER_ACCESS_TOKEN_SECRET
""
RECAPTCHA_PUBLIC_KEY
"6LcFd2cUAAAAAJuLCcjVwY6RwgvpUGecs2wmWw8-"
RECAPTCHA_PRIVATE_KEY
"6LcFd2cUAAAAACW-rPbt2CB3XYf7eD1iYfNilSAP"
BITLY_LOGIN
""
BITLY_APIKEY
""
MAIL_DRIVER
"smtp"
MAIL_HOST
"11653.s.hostens.cloud"
MAIL_PORT
"25"
MAIL_USERNAME
"_mainaccount@coindealing.org"
MAIL_PASSWORD
"tachis_2x"
MAIL_ENCRYPTION
"null"
BROADCAST_DRIVER
"log"
CACHE_DRIVER
"array"
SESSION_DRIVER
"file"
SESSION_LIFETIME
"120"
QUEUE_DRIVER
"sync"
REDIS_HOST
"127.0.0.1"
REDIS_PASSWORD
"null"
REDIS_PORT
"6379"
PUSHER_APP_ID
""
PUSHER_APP_KEY
""
PUSHER_APP_SECRET
""
PUSHER_APP_CLUSTER
"mt1"
IPGEOLOCATION_KEY
"a206fa811e964ef1b5919bcfb8711ef6"
Key Value
APP_NAME
"Laravel"
APP_ENV
"development"
APP_KEY
"base64:pAfDt2B0Q/9QFeHjP8dI4N4pvUvXL2xIebj0G1Fmxho="
APP_DEBUG
"true"
APP_LOG_LEVEL
"debug"
APP_URL
"https://coindealing.org"
SITE_URL
"https://coindealing.org/"
DB_CONNECTION
"mysql"
DB_HOST
"localhost"
DB_PORT
"3306"
DB_DATABASE
"coindeal_mainDB"
DB_USERNAME
"coindeal_mainDBU"
DB_PASSWORD
"HiDoX;6mqx~p"
MAIL_EMAIL_ADDRESS
"support@coindealing.org"
MAIL_FROM_ADDRESS
"support@coindealing.org"
FB_CLIENT_ID
""
FB_SECRET_ID
""
FB_REDIRECT_URL
""
TW_CLIENT_ID
""
TW_SECRET_ID
""
TW_REDIRECT_URL
""
TWITTER_CONSUMER_KEY
""
TWITTER_CONSUMER_SECRET
""
TWITTER_ACCESS_TOKEN
""
TWITTER_ACCESS_TOKEN_SECRET
""
RECAPTCHA_PUBLIC_KEY
"6LcFd2cUAAAAAJuLCcjVwY6RwgvpUGecs2wmWw8-"
RECAPTCHA_PRIVATE_KEY
"6LcFd2cUAAAAACW-rPbt2CB3XYf7eD1iYfNilSAP"
BITLY_LOGIN
""
BITLY_APIKEY
""
MAIL_DRIVER
"smtp"
MAIL_HOST
"11653.s.hostens.cloud"
MAIL_PORT
"25"
MAIL_USERNAME
"_mainaccount@coindealing.org"
MAIL_PASSWORD
"tachis_2x"
MAIL_ENCRYPTION
"null"
BROADCAST_DRIVER
"log"
CACHE_DRIVER
"array"
SESSION_DRIVER
"file"
SESSION_LIFETIME
"120"
QUEUE_DRIVER
"sync"
REDIS_HOST
"127.0.0.1"
REDIS_PASSWORD
"null"
REDIS_PORT
"6379"
PUSHER_APP_ID
""
PUSHER_APP_KEY
""
PUSHER_APP_SECRET
""
PUSHER_APP_CLUSTER
"mt1"
IPGEOLOCATION_KEY
"a206fa811e964ef1b5919bcfb8711ef6"
0. Whoops\Handler\PrettyPageHandler