Skip to content

Commit

Permalink
refactor: validate array prior to adding tags on v2 forms (#8)
Browse files Browse the repository at this point in the history
* rwfactor: check array type

* refactor: conditionally apply tags to subscriber

* refactor: cast array
  • Loading branch information
JoshuaHungDinh authored May 14, 2024
1 parent 9bcd787 commit 4003016
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion give-activecampaign.php
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ public function subscribe_email( $user_info = [], $lists = [], $tags = [] ) {
"email" => $user_info['email'],
"first_name" => $user_info['first_name'],
"last_name" => $user_info['last_name'],
"tags" => implode( ', ', $tags ),
"tags" => implode( ', ', (array)$tags ),
];

foreach ( $lists as $list ) {
Expand Down

0 comments on commit 4003016

Please sign in to comment.