Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Element is undefined in struct - throws error #9

Open
murrah opened this issue May 24, 2017 · 0 comments
Open

Element is undefined in struct - throws error #9

murrah opened this issue May 24, 2017 · 0 comments

Comments

@murrah
Copy link

murrah commented May 24, 2017

I am testing your CFC by throwing it curved balls. eg

s = {
	a = "abc",
	b = javaCast('null', 0),
	c = "123"
};

This threw an error at line 277 where this fails: serializeInput( input[ key ], hint );

I replaced that line with

if ( structKeyExists(input, key) ) {
	serializeInput( input[ key ], hint );	
} else {
	writeOutput('""');
}

ie output an empty string. BUT... maybe should output writeOutput('"null"'); ????

I didn't make a PR because I am not sure I know what I am doing with GitHub and none of the other PRs seem to have been acted on. ;-)

Thanks Ben!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant