A return statement in irScript is used to exit a function and, optionally, specify a return value.
var x = function () { return 33; };
var y = x();
function DoStuff( arg )
{
arg.SomeProperty = x();
if( arg.SomeProperty > 100 )
{
return;
}
else
{
arg.SomeOtherProperty = 'some value';
}
}
var z = { Class : 'MyObject' };
DoStuff(z);
Comments
0 comments
Please sign in to leave a comment.