[coldbox-3.5.2] MailService error after 3.5.2 upgrade

I just tried running with 3.5.2 over 3.5.0, and none of my email functions seem to be working.

According to the error, the server isn’t defined, but it is in Coldbox.cfc:

mailSettings = {

server = “email-smtp.us-east-1.amazonaws.com”,

username = “AKIAI3EY3YSO******”,

defaultType=“HTML”,

password = “AsBr0dGv8iX6TJf0RPnihRzMh******”,

port = 25

};

If I revert back to 3.5.0, it works again!?!

I looked at MailService.cfc, and the only thing that seems to have changed is some defaults around replyTo and other “fields”.

Here’s the stack trace. Anyone any ideas??

coldfusion.runtime.UndefinedElementException: Element SERVER is undefined in ARGUMENTS.

at coldfusion.runtime.DotResolver.resolveSplitNameInMap(DotResolver.java:109)

at coldfusion.runtime.CfJspPage._resolve(CfJspPage.java:1615)

at coldfusion.runtime.CfJspPage._resolveAndAutoscalarize(CfJspPage.java:1794)

at coldfusion.runtime.CfJspPage._resolveAndAutoscalarize(CfJspPage.java:1787)

at cfMail2ecfc21442216$funcCONFIG.runFunction(/fs/sites/ebiz/resources/com/coldbox/system/core/mail/Mail.cfc:79)

at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)

at coldfusion.filter.SilentFilter.invoke(SilentFilter.java:47)

at coldfusion.runtime.UDFMethod$ReturnTypeFilter.invoke(UDFMethod.java:405)

at coldfusion.runtime.UDFMethod$ArgumentCollectionFilter.invoke(UDFMethod.java:368)

at coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:55)

at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)

at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:517)

at coldfusion.runtime.CfJspPage._invokeUDF(CfJspPage.java:2547)

at cfMail2ecfc21442216$funcINIT.runFunction(/fs/sites/ebiz/resources/com/coldbox/system/core/mail/Mail.cfc:28)

at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)

at coldfusion.filter.SilentFilter.invoke(SilentFilter.java:47)

at coldfusion.runtime.UDFMethod$ReturnTypeFilter.invoke(UDFMethod.java:405)

at coldfusion.runtime.UDFMethod$ArgumentCollectionFilter.invoke(UDFMethod.java:368)

at coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:55)

at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)

at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:517)

at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:496)

at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:355)

at coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2301)

at cfMailService2ecfc1653663266$funcNEWMAIL.runFunction(/fs/sites/ebiz/resources/com/coldbox/system/core/mail/MailService.cfc:55)

at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)

at coldfusion.filter.SilentFilter.invoke(SilentFilter.java:47)

at coldfusion.runtime.UDFMethod$ReturnTypeFilter.invoke(UDFMethod.java:405)

at coldfusion.runtime.UDFMethod$ArgumentCollectionFilter.invoke(UDFMethod.java:368)

at coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:55)

at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)

at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)

at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:491)

at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:337)

at coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2360)

Hi Tom Miller,

I have already forward the fixes to Luis, hopefully it will be fixed soon.

Thanks

Hi Sana,

Can I see what those fixes are? I’m happy to patch my version here quickly – unless it’s not a quick fix? I’m kinda desperate!

Thanks,

Tom.

Try below code.

system/core/mail/Mail.cfc Line 79

if( NOT len( arguments.server ) ){
structDelete( instance, “server” );
}

this should be like this

if( StructKeyExists(arguments, “server”) and NOT len( arguments.server ) ){
structDelete( instance, “server” );
}

Thanks Fixed!

Luis F. Majano
CEO
Ortus Solutions, Corp
www.ortussolutions.com

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

Social: twitter.com/lmajano facebook.com/lmajano