Im having a problem where laravel is sometimes returning null for my environment variables after location.reload();
What makes it really annoying is that it doesent seem to be 100% reproducable and i cant pin down in what exact situations it happens.
In my blade tempalte i have the follwoing code:
<?php
$env = env('asdfasdf');
if($env != null){
print "<!-- not null " . env('asdfasdf') . " -->";
} else {
print "<!-- null " . env('asdfasdf') . " -->";
}
?>
On first page load i always get <!-- not null asdfasdf ->
as the result. But when i trigger javascript location.reload();
then sometimes i get <!-- null -->
.
Any ideas?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire