save lang in idb

This commit is contained in:
tamaina
2021-01-23 00:56:06 +09:00
parent e08cfff613
commit c44c95d6dd
8 changed files with 66 additions and 47 deletions

View File

@@ -1,10 +1,15 @@
/**
* Notification composer of Service Worker
*/
declare var self: ServiceWorkerGlobalScope;
import { getNoteSummary } from '../../misc/get-note-summary';
import getUserName from '../../misc/get-user-name';
export default async function(type, data, i18n): Promise<[string, NotificationOptions] | null> {
export default async function(type, data, i18n): Promise<[string, NotificationOptions] | null | undefined> {
if (!i18n) {
console.log('no i18n');
return null;
return;
}
switch (type) {