Skip to content
Snippets Groups Projects
Commit f677d87d authored by Dorian Merz's avatar Dorian Merz
Browse files

refs #15956 [fid] fix in lightbox_form_cache.js

* adds textareas to cached input elements
parent 1830d8c2
Branches
Tags
No related merge requests found
......@@ -26,7 +26,8 @@ document.addEventListener('DOMContentLoaded', function () {
const cacheKeyBase = Array.from(form.attributes).map(attr => attr.value);
const cacheKey = cacheKeyPrefix + btoa(cacheKeyBase.join());
const inputs = Array.from(form.querySelectorAll('input:not([type=password])'));
const inputs = Array.from(form.querySelectorAll('input:not([type=password])'))
.concat(Array.from(form.querySelectorAll('textarea')));
JSON.parse(cache.getItem(cacheKey) || '[]').forEach(function (value, index) {
inputs[index].value = value;
});
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment