change DatabaseError.php file name to DatabaseException.php
use exception for database error instead of die()