Merge commit '08864f79347e912e990f5ce0e86e5a8e739dc29d'

Conflicts:
	VERSION
	airtime_mvc/application/configs/conf.php
	airtime_mvc/application/models/Shows.php
This commit is contained in:
Paul Baranowski 2011-04-25 18:49:51 -04:00
commit d14dc6cbe3
2 changed files with 15 additions and 6 deletions

View file

@ -60,7 +60,10 @@ function airtime_empty_db($db)
Playlist::deleteAll();
echo " * Clearing files table...".PHP_EOL;
StoredFile::deleteAll();
$result = StoredFile::deleteAll();
if (PEAR::isError($result)) {
echo $result->getMessage().PHP_EOL;
}
}
@ -89,6 +92,12 @@ if (isset($opts->h)) {
exit;
}
// Need to check that we are superuser before running this.
if (exec("whoami") != "root") {
echo PHP_EOL."You must be root to use this script.".PHP_EOL.PHP_EOL;
exit(1);
}
$CC_DBC = DB::connect($CC_CONFIG['dsn'], TRUE);
$CC_DBC->setFetchMode(DB_FETCHMODE_ASSOC);