@pmate/cli 0.21.15 → 0.21.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +14 -0
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -16098,6 +16098,19 @@ function buildListThreadsExpr() {
16098
16098
  }
16099
16099
  return null;
16100
16100
  }
16101
+ function isArchived(model) {
16102
+ var attrs = typeof model.attributes === 'object' ? model.attributes : model || {};
16103
+ var candidates = [
16104
+ attrs.isArchived,
16105
+ attrs.archived,
16106
+ model && model.get ? model.get('isArchived') : null,
16107
+ model && model.get ? model.get('archived') : null,
16108
+ ];
16109
+ for (var i = 0; i < candidates.length; i++) {
16110
+ if (candidates[i] === true) return true;
16111
+ }
16112
+ return false;
16113
+ }
16101
16114
  var all = [];
16102
16115
  if (typeof controller.getAllPrivateConversations === 'function') {
16103
16116
  var privates = controller.getAllPrivateConversations();
@@ -16114,6 +16127,7 @@ function buildListThreadsExpr() {
16114
16127
  var conversationId = normalize(model && model.get ? model.get('id') : model && model.id);
16115
16128
  if (!conversationId || seen[conversationId]) continue;
16116
16129
  seen[conversationId] = true;
16130
+ if (isArchived(model)) continue;
16117
16131
  var name = pickName(model);
16118
16132
  if (!name) continue;
16119
16133
  threads.push({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pmate/cli",
3
- "version": "0.21.15",
3
+ "version": "0.21.16",
4
4
  "description": "CLI utilities for the pMate project",
5
5
  "license": "MIT",
6
6
  "bin": {