Utility functions that are required to be re-used throughout the runner
- Source:
Methods
(static) safeCall(fn, ctx) → {Error}
This function allows one to call another function by wrapping it within a try-catch block. The first parameter is the function itself, followed by the scope in which this function is to be executed. The third parameter onwards are blindly forwarded to the function being called
Parameters:
Name | Type | Description |
---|---|---|
fn |
function | |
ctx |
* |
- Source:
Returns:
If there was an error executing the function, the error is returned. Note that if the function called here is asynchronous, it's errors will not be returned (for obvious reasons!)
- Type
- Error
(static) syncObject(dest, src) → {Object}
Copies attributes from source object to destination object.
Parameters:
Name | Type | Description |
---|---|---|
dest |
||
src |
- Source:
Returns:
- Type
- Object