I can't split up a string using Functions. This is an SMS app in Studio:
User texts his full name to Twilio, I call a function and add the Liquid variable with their full name and send it to a Function where I want to return only the first name.
exports.handler = function(context, event, callback) {
var firstName = event.fullName.split(' ');
callback(null, firstName[0]);
};
error message:Cannot read property 'split' of undefined