function isObjectEmpty(obj) { return Object.keys(obj).length === 0; }
function isEmptyObject(obj) { return !Object.keys(obj).length; }
var empty_obj = {};
if(Object.keys(obj).length === 0) { }