Évite de planter si on demande un calendrier inexistant

This commit is contained in:
Tom Hubrecht 2022-03-29 20:30:47 +02:00
parent 6f96c37358
commit c72d565eba

View file

@ -75,6 +75,11 @@
const flatten = d => {
let array = [];
if (!d) {
return [];
}
if (Array.isArray(d)) {
d.forEach(a => (array = array.concat(flatten(a))));
} else {