Updated models/template.class.php to utilize the updated Theme class