aboutsummaryrefslogtreecommitdiff
path: root/editor/state
diff options
context:
space:
mode:
Diffstat (limited to 'editor/state')
-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
-
-