Adding support for mapping over other data types such as promises and jQuery objects