Add option to ignore entries matching a pattern (#161)
* Add option to ignore entries matching a pattern
This commit is contained in:
@@ -121,7 +121,8 @@ async function updateMatchingPasswordsCount(tabId) {
|
||||
throw new Error(`Unable to determine domain of the tab with id ${tabId}`);
|
||||
}
|
||||
|
||||
const logins = helpers.prepareLogins(response.data.files, settings);
|
||||
const files = helpers.ignoreFiles(response.data.files, settings);
|
||||
const logins = helpers.prepareLogins(files, settings);
|
||||
const matchedPasswordsCount = logins.reduce(
|
||||
(acc, login) => acc + (login.recent.count || login.inCurrentDomain ? 1 : 0),
|
||||
0
|
||||
@@ -714,7 +715,8 @@ async function handleMessage(settings, message, sendResponse) {
|
||||
if (response.status != "ok") {
|
||||
throw new Error(JSON.stringify(response)); // TODO handle host error
|
||||
}
|
||||
sendResponse({ status: "ok", files: response.data.files });
|
||||
let files = helpers.ignoreFiles(response.data.files, settings);
|
||||
sendResponse({ status: "ok", files });
|
||||
} catch (e) {
|
||||
sendResponse({
|
||||
status: "error",
|
||||
|
Reference in New Issue
Block a user