refactor SwiftMessage creation

this fixes an issue reported by Scrutinizer:
  \$message of type object<Swift_Mime_MimePart> is not a sub-type
  of object<Swift_Message>
define undefined fields in legacy WorkPage