Revision 093ec2a5
Added by koszko over 1 year ago
| html/settings.js | ||
|---|---|---|
| 134 | 134 |
set_up_repos_tab(); |
| 135 | 135 |
} |
| 136 | 136 |
|
| 137 |
async function init_settings_page() {
|
|
| 137 | 138 |
#IF MOZILLA |
| 138 |
async function show_indexeddb_error() {
|
|
| 139 | 139 |
const this_tab = await browser.tabs.getCurrent(); |
| 140 |
if (this_tab.incognito) |
|
| 141 |
by_id("indexeddb_private_mode_explanation").classList.remove("hide");
|
|
| 142 |
#ELSE |
|
| 143 |
function show_indexeddb_error() {
|
|
| 140 |
|
|
| 141 |
if (this_tab.incognito) {
|
|
| 142 |
by_id("private_mode_error").classList.remove("hide");
|
|
| 143 |
by_id("loader").remove();
|
|
| 144 |
return; |
|
| 145 |
} |
|
| 144 | 146 |
#ENDIF |
| 145 |
by_id("loader").remove();
|
|
| 146 |
by_id("indexeddb_error").classList.remove("hide");
|
|
| 147 |
} |
|
| 148 | 147 |
|
| 149 |
async function init_settings_page() {
|
|
| 150 | 148 |
try {
|
| 151 | 149 |
await haketilodb.get(); |
| 152 | 150 |
} catch(e) {
|
| 153 | 151 |
console.error("Haketilo:", e);
|
| 154 |
show_indexeddb_error(); |
|
| 152 |
by_id("indexeddb_error").classList.remove("hide");
|
|
| 153 |
by_id("loader").remove();
|
|
| 155 | 154 |
return; |
| 156 | 155 |
} |
| 157 | 156 |
|
Also available in: Unified diff
correct the Private Browsing mode notice on settings page