Quantcast
Channel: Yii Framework Forum
Viewing all articles
Browse latest Browse all 18717

I Wasted 12 Hours

$
0
0
I wasted 12 hours debugging this ...
$total = 0;
foreach($model->rels as $rel);
{
    $total += $rel->count;
}
echo $total; // wrong result!!


Who in the hell wrote that wicked semicolon? Me?
In the real source, the relation was a little bit complicated, and I wasted time examining it.

Viewing all articles
Browse latest Browse all 18717

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>