Skip to content

Commit

Permalink
Bugfix: Upgrade separator position,
Browse files Browse the repository at this point in the history
Bugfix: Favicon loading,
Bugfix: Url updating
  • Loading branch information
Kiuryy committed Feb 20, 2018
1 parent cce12ec commit 72327f5
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 11 deletions.
2 changes: 1 addition & 1 deletion dist/js/background.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/js/extension.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"cp-file": "^5.0.0",
"create-file": "^1.0.1",
"del": "^3.0.0",
"eslint": "^4.18.0",
"eslint": "^4.18.1",
"glob-concat": "^1.0.1",
"html-minifier": "^3.5.9",
"jsonminify": "^0.4.1",
Expand Down
2 changes: 1 addition & 1 deletion src/js/background/image.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@
let now = +new Date();

Object.keys(cache).forEach((key) => {
if (now - cache[key].t > 1000 * 60 * 60 * 24 * 5) { // older than 5 days
if (now - cache[key].t > 1000 * 60 * 60 * 24 * 3) { // older than 3 days
delete cache[key];
}
});
Expand Down
4 changes: 2 additions & 2 deletions src/js/background/upgrade.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,13 +118,13 @@
try {
Object.entries(d.utility.separators).forEach(([parentId, separators]) => {
if (separators && separators.length > 0) {
separators.forEach((separator) => {
separators.forEach((separator, i) => {
b.preventReload = true;
b.helper.bookmarkApi.func.create({
title: "----------",
url: "about:blank",
parentId: parentId,
index: separator.index || 0
index: (separator.index || 0) + i
});
});
}
Expand Down
8 changes: 4 additions & 4 deletions src/js/extension.js
Original file line number Diff line number Diff line change
Expand Up @@ -225,16 +225,16 @@
* Initialises the not yet loaded images in the sidebar
*/
this.initImages = () => {
if (this.elements.iframe.hasClass(opts.classes.page.visible)) {
$.delay(0).then(() => {
$.delay().then(() => {
if (this.elements.iframe.hasClass(opts.classes.page.visible)) {
this.elements.sidebar.find("img[" + opts.attr.src + "]").forEach((_self) => {
let img = $(_self);
let src = img.attr(opts.attr.src);
img.removeAttr(opts.attr.src);
img.attr("src", src);
});
});
}
}
});
};

/**
Expand Down
3 changes: 2 additions & 1 deletion src/js/helper/overlay.js
Original file line number Diff line number Diff line change
Expand Up @@ -811,7 +811,6 @@
if (entries[i]) { // go through the list one by one and update or delete the bookmark
if ($(entries[i]).find("input[type='checkbox']")[0].checked) {
let entry = $(entries[i]).data("entry");
console.log(entry);

new Promise((rslv) => {
if (entry.urlStatusCode === 404) {
Expand All @@ -832,6 +831,8 @@
}).then(() => {
proceedList(i + 1);
});
} else {
proceedList(i + 1);
}
} else { // all elements iterated -> close overlay and reload sidebar
resolve();
Expand Down

0 comments on commit 72327f5

Please sign in to comment.