Fixed issue where an empty title could raise error

Ran into an error where an undefined `title` caused a problem.