Modules

filter

 

Objects/Functions

module (N/util)

SuiteScript 2.0

util.isFunction(obj)

{util}.isFunction(obj){obj: {Object | Primitive*}})

N/util Module
util.isFunction(obj)
Method Description: Returns true if the obj parameter is a JavaScript Function or AsyncFunction and false otherwise.
Returns: boolean
Supported Script Types: All script types For more information, see SuiteScript 2.0 Script Types.
Governance: None
Module: N/util Module
Since: 2016.1
Search NetSuite - https://system.netsuite.com/app/help/helpcenter.nl?search=util.isFunction(obj)

Example:

// Code Example 1
//Add additional code
//...
function test() {};
var test2 = function() {};

util.isFunction(test); // returns true
util.isFunction(test2); // returns true
//...
//Add additional code

//SOURCE: https://system.netsuite.com/app/help/helpcenter.nl?fid=section_4434697652.html