added support for an optional title.