only coerce once

pull/2357/head
Rich Harris 6 years ago committed by GitHub
parent 6ef8137b4b
commit 2b7b1c7e91
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -154,7 +154,8 @@ export function claim_text(nodes, data) {
}
export function set_data(text, data) {
if (text.data !== '' + data) text.data = '' + data;
data = '' + data;
if (text.data !== data) text.data = data;
}
export function set_input_type(input, type) {
@ -236,4 +237,4 @@ export function custom_event(type, detail) {
const e = document.createEvent('CustomEvent');
e.initCustomEvent(type, false, false, detail);
return e;
}
}

Loading…
Cancel
Save