Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
#set ($original = $message.getFrom()[0].getAddress().toLowerCase()) ##Extracts the Value found within the From header
#if ($original.endsWith("@thepluginpeople.com"))  ##checks if sender address is a specific address
    #set ($name = $original.split("@")[0])
    $message.setFrom($name + "@replaced.com") ##Changes original from address to be the extracted name and email address
#end

...