Open-source IoT Platform - Device management, data collection, processing and visualization.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

17 lines
333 B

// tryor.js
// MIT licensed, see LICENSE file
// Copyright (c) 2013 Olov Lassus <olov.lassus@gmail.com>
function tryor(fn, v) {
"use strict";
try {
return fn();
} catch (e) {
return v;
}
};
if (typeof module !== "undefined" && typeof module.exports !== "undefined") {
module.exports = tryor;
}