JavaScript: don't choke when returning object literals