this.publicKeysOptions = ko.computed(function () { return _.compact(_.map(PgpStore.openpgpkeysPublic(), function (oKey) { return -1 < Utils.inArray(oKey, self.encryptKeysView()) ? null : { 'id': oKey.guid, 'name': '(' + oKey.id.substr(-6) + ') ' + oKey.user, 'key': oKey }; })); });
this.publicKeysOptions = ko.computed(function() { return _.compact(_.flatten(_.map(PgpStore.openpgpkeysPublic(), function(oKey, iIndex) { return -1 < Utils.inArray(oKey, self.encryptKeysView()) ? null : _.map(oKey.users, function(sUser) { return { 'id': oKey.guid, 'name': '(' + oKey.id.substr(-8).toUpperCase() + ') ' + sUser, 'key': oKey, 'class': iIndex % 2 ? 'odd' : 'even' }; }); }), true)); });