<?php
$_db_migration_to = '34.07'; // 8.8.4
if (!isset($migrations) || !is_object($migrations))
	die("This file cannot be executed directly");
$migrations->CheckValid($_db_migration_to);
//===========================================================================================



$migrations->Run('01_subscribers_notified.php', <<<'DB_UPDATE_FILE'
<?php
/** @var $migrations \Claromentis\Setup\SetupFacade */
$db = $migrations->GetDb();

//this ensures that no currently existing news has its subscribers
$db->AddColumn('news', 'subscribers_notified', 'BOOL DEFAULT 0');
$db->query("UPDATE news SET subscribers_notified=1");

DB_UPDATE_FILE
);


//===========================================================================================
$migrations->SetVersion('34.07');
