0e524f3e9a
* WIP: detect private browsing and safari blocked cookies * just check for indexeddb * just check for indexeddb * change warning text * change text * change text again * change text again fixes #444
12 lines
168 B
JavaScript
12 lines
168 B
JavaScript
export function thunk (func) {
|
|
let cached
|
|
let runOnce
|
|
return () => {
|
|
if (!runOnce) {
|
|
cached = func()
|
|
runOnce = true
|
|
}
|
|
return cached
|
|
}
|
|
}
|