summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSébastien Dailly <sebastien@chimrod.com>2021-10-19 13:29:49 +0200
committerSébastien Dailly <sebastien@dailly.me>2022-02-07 16:43:33 +0100
commitf7dc93dab194472329d74c056c4730b41e98d650 (patch)
treef700382206abab6e5632be97ddcf27a7893de226
parent12d8d9e671ed8010c5a17183b304dd7357411200 (diff)
Update to latest Brr library
-rwxr-xr-xeditor/state/storage.ml8
1 files changed, 3 insertions, 5 deletions
diff --git a/editor/state/storage.ml b/editor/state/storage.ml
index 4688881..a10e75f 100755
--- a/editor/state/storage.ml
+++ b/editor/state/storage.ml
@@ -128,14 +128,14 @@ let get_ids
let storage = Storage.local G.window in
let items = Storage.length storage in
- let sub = Jstr.( storage_key + (v "_") ) in
- let start = Jstr.length sub in
+ let prefix = Jstr.( storage_key + (v "_") ) in
+ let start = Jstr.length prefix in
let rec add_element acc = function
| -1 -> acc
| nb ->
begin match Storage.key storage nb with
- | Some key when (Jstr.starts_with ~sub key) ->
+ | Some key when (Jstr.starts_with ~prefix key) ->
let key_name = Jstr.sub key
~start in
@@ -188,5 +188,3 @@ let of_json
key
))
result
-
-