PHP warning

Trying to access array offset on value of type bool

/var/www/barev-front/www/protected/controllers/SiteController.php(428)

416             $now_item[0] = 0;
417             $lines = 3;
418             $length[0] = 0;
419             $count = 0;
420             $last = 10000000;
421             
422             while(1){
423             
424                 $sql1 = " SELECT * FROM `news_tags` WHERE id_tag = '$id_tag' AND id_news < $last ORDER BY id_news DESC LIMIT 1 ";
425                 $command1=$connection->createCommand($sql1);
426                 $dataReader1=$command1->query();
427                 $row1=$dataReader1->read();
428                 $id_news = $row1['id_news'];
429             
430                 
431                 
432                 $sql = " SELECT * FROM `news` WHERE id = '$id_news' ";
433                 $command=$connection->createCommand($sql);
434                 $dataReader=$command->query();
435                 $row=$dataReader->read();
436                 
437                 if(!isset($row['id']))
438                     break;
439                 
440                 $id = $row['id'];

Stack Trace

#7
+
 /var/www/barev-front/www/index.php(13): CApplication->run()
08 defined('YII_DEBUG') or define('YII_DEBUG',true);
09 // specify how many levels of call stack should be shown in each log message
10 defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3);
11 
12 require_once($yii);
13 Yii::createWebApplication($config)->run();
2024-03-19 05:20:24 nginx/1.18.0 Yii Framework/1.1.15