I am getting this error in my domain where I have used laravel v8 for my site.

It shows error in line no 52 in index file:

Previously my .env file was not reading. As soon as I fixed that error I got this one now. Please help me solve this error.
Advertisement
Answer
This issue might occur due to change in APP_KEY value in your .env file.
APP_KEY is used for secure data transmission and Laravel recommends to do that by setting it to a random string.
This
APP_KEYis used for
- Encrypting cookies.
 - Creating the signature for signed URLs and queued closures.
 - Encrypting values using the encrypt() and decrypt() helpers.
 
A encrypted data can be decrypted if you use the same key which was used while encrypting.
So if possible look for a backup .env file and use the same APP_KEY to resolve it.
