lib/mail/Mail.php
public function addGlobalSubstitutions($substitutions)
    {
        if (current($substitutions) instanceof Substitution) {
            foreach ($substitutions as $substitution) {
                $this->addGlobalSubstitution($substitution);
            }
        } else {
            foreach ($substitutions as $key => $value) {
                $this->addGlobalSubstitution($key, $value);
            }
        }
    }
public function addGlobalSubstitutions($substitutions)
    {
        if (current($substitutions) instanceof Substitution) {
            foreach ($substitutions as $substitution) {
                $this->addGlobalSubstitution($substitution);
            }
        } else {
            foreach ($substitutions as $key => $value) {
                $this->addGlobalSubstitution($key, $value);
            }
        }
    }
public function addGlobalSubstitutions ( $ substitutions ) { if ( current ( $ substitutions ) instanceof Substitution ) { foreach ( $ substitutions as $ substitution ) { $ this -> addGlobalSubstitution ( $ substitution ) ; } } else { foreach ( $ substitutions as $ key => $ value ) { $ this -> addGlobalSubstitution ( $ key , $ value ) ; } } }
Adds multiple substitutions to a Mail object

Note that substitutions added to Personalization objects override
global headers.

@param array|Substitution[] $substitutions Array of Substitution
objects or key/values
Adds multiple substitutions to a Mail object