Is this just me or are there sudden changes I'm not aware of. Is this behavior the correct?
beforeSubmit(type) { nlapiLogExecution('Debug', 'in before submit', 'Type = '+type+', typeof: '+typeof(type)); switch(type) { case 'delete' : // execute here nlapiLogExecution('Debug', 'in delete case', 'Type = '+type+', typeof: '+typeof(type)); case 'create' : // execute here nlapiLogExecution('Debug', 'in create case', 'Type = '+type+', typeof: '+typeof(type)); default: // do nothing nlapiLogExecution('Debug', 'in default, 'Type = '+type+', typeof: '+typeof(type)); } }When I run the log execution I get the following for a delete operation:Debug in before submit Type = delete, typeof: objectDebug in default Type = delete, typeof: objectThe switch statement fails because the type parameter is passing an object (of what, I have no idea, but not a string). In the past I always looked at this as a string so I can not believe that scripts all over are working just fine if this is the case.Am I missing something?UPDATE:If I use an if statement instead of the switch statement it works fine. I noticed this the other day on another function where I was comparing a numeric value that was a string to a numeric value that was an integer. If statement compared them fine, switch statement did not make the conversion thus always failed to match even when equal. I never noticed this behavior before.-Steve