maybeAddToMap<T1, T2> function
Adds add
to source
if both are not null.
Implementation
Map<T1, T2>? maybeAddToMap<T1, T2>(Map<T1, T2>? source, Map<T1, T2>? add) {
if (source == null) return source;
if (add == null) return source;
return {...source, ...add};
}