This should be simple but for some reason code in my if
block is executing despite the fact that it resolves to false
and it's making me very unhappy... My user_id in this case is 2
.
$note = Notification::where("user_id",Auth::user()->id)->first();
$wall = $note->pluck('wall');
if($wall != 0)
{
//This code is executing!
}
else{
array_push($data,"Your First Time!");
//This code is not!
}
As you can see, my $wall should be zero so I don't understand why $wall != 0
runs.
from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/1WXItaE
via IFTTT
Aucun commentaire:
Enregistrer un commentaire