Email Validation Error when adding velocity token for Opportunity field data
Hi Community!
I'm hoping someone could help me with an issue I'm having with a velocity script token. After I add the token to an email, I receive an error when I try to approve.

Here's the code I've set up:
#set ($string = "$OpportunityList.get(0).Document_Links__c" )
#set ($output = $string.split('\n'))
#set ($docLa = "$output[0]" )
#set ($docLb = "$output[1]" )
The variables are then used in separate script tokens and added to the email to display the output data.
{{my.doclink-url-1}}

In the Email:
<a href="{{my.doclink-url-1}}" style="font-weight: bold;">{{my.Dynamic-DisplayBrandNameA}} Regular Guarantee</a> <br /><br />
<a href="{{my.doclink-url-2}}" style="font-weight: bold;">{{my.Dynamic-DisplayBrandNameA}} Regular Terms</a>
This code was working for a time then all the sudden stopped recently (I'm guessing maybe it shouldn't have worked the first time)
Interestingly, if I remove the last line in the code, I can approve the email normally.
Any help would be much appreciated! Thank you!!