Files
zulip/static/js
Zev Benjamin 3f95e54dc1 dict: Add setdefault method
This is like Python's dict.setdefault.  I don't love the name, but
the consistency is nice.

We have lots of places where we do things like:

    if (! dict.has('foo')) {
      dict.set('foo', []);
    }

    var arr = dict.get('foo');
    arr.push(3);

We can now write:

    var arr = dict.setdefault('foo', []);
    arr.push(3);

(imported from commit b8933809c69ba47ec346ed51d53966793403e56c)
2013-08-21 14:11:39 -04:00
..
2013-07-29 12:11:26 -04:00
2013-07-30 12:12:58 -04:00
2013-08-21 14:11:39 -04:00
2013-07-30 12:12:58 -04:00
2013-08-20 14:27:43 -04:00
2013-08-13 14:12:28 -04:00
2013-07-30 12:12:58 -04:00
2013-08-19 12:17:55 -04:00
2013-07-30 12:12:58 -04:00
2013-08-19 12:17:55 -04:00
2013-08-15 18:04:43 -04:00
2013-07-29 12:11:26 -04:00
2013-07-29 12:11:26 -04:00
2013-08-20 14:27:42 -04:00
2013-08-19 12:17:55 -04:00
2013-08-13 11:26:12 -04:00
2013-08-19 12:17:55 -04:00
2013-07-30 12:12:58 -04:00
2013-08-09 17:12:23 -04:00
2013-08-20 15:37:08 -04:00