release v1
This commit is contained in:
1 parent
df4ea523fe
commit
c607b751c2
540 files changed
+92301
-5
No files matched your search
+12
@@ -0,0 +1,12 @@
|
||||
'use strict'
|
||||
|
||||
/**
|
||||
* Tries to execute a function and discards any error that occurs.
|
||||
* @param {Function} fn - Function that might or might not throw an error.
|
||||
* @returns {?*} Return-value of the function when no error occurred.
|
||||
*/
|
||||
module.exports = function(fn) {
|
||||
|
||||
try { return fn() } catch (e) {}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user