@ecency/sdk 1.5.18 → 1.5.19

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.
@@ -216,12 +216,13 @@ var ConfigManager;
216
216
  return null;
217
217
  }
218
218
  }
219
- function setDmcaLists(accounts = {}) {
219
+ function setDmcaLists(lists = {}) {
220
220
  const coerceList = (value) => Array.isArray(value) ? value.filter((item) => typeof item === "string") : [];
221
+ const input = lists || {};
221
222
  const resolved = {
222
- accounts: coerceList(accounts.accounts),
223
- tags: coerceList(accounts.tags),
224
- patterns: coerceList(accounts.posts)
223
+ accounts: coerceList(input.accounts),
224
+ tags: coerceList(input.tags),
225
+ patterns: coerceList(input.posts)
225
226
  };
226
227
  CONFIG.dmcaAccounts = resolved.accounts;
227
228
  CONFIG.dmcaTags = resolved.tags;
@@ -1848,7 +1849,7 @@ function getAccountPostsInfiniteQueryOptions(username, filter = "posts", limit =
1848
1849
  ...pageParam.permlink ? { start_permlink: pageParam.permlink } : {}
1849
1850
  };
1850
1851
  try {
1851
- if (CONFIG.dmcaAccounts.includes(username)) return [];
1852
+ if (CONFIG.dmcaAccounts && CONFIG.dmcaAccounts.includes(username)) return [];
1852
1853
  const resp = await CONFIG.hiveClient.call(
1853
1854
  "bridge",
1854
1855
  "get_account_posts",