src/Model/Template.php
public function format() {

        /*         * Add the mandatary props* */
        if (!is_null($this->name)) {
            $result[self::NAME_KEY] = $this->name;
        }

        /*         * Add the optional props if any* */
        if (!is_null($this->optionalProperties)) {
            $result = array_merge($result, $this->optionalProperties);
        }


        return $result;
    }
public function format() {

        /*         * Add the mandatary props* */
        if (!is_null($this->name)) {
            $result[self::NAME_KEY] = $this->name;
        }

        /*         * Add the optional props if any* */
        if (!is_null($this->optionalProperties)) {
            $result = array_merge($result, $this->optionalProperties);
        }


        return $result;
    }
public function format ( ) { /*         * Add the mandatary props* */ if ( ! is_null ( $ this -> name ) ) { $ result [ self :: NAME_KEY ] = $ this -> name ; } /*         * Add the optional props if any* */ if ( ! is_null ( $ this -> optionalProperties ) ) { $ result = array_merge ( $ result , $ this -> optionalProperties ) ; } return $ result ; }
Format Template for MailJet API request
@return array
Format Template for MailJet API request