setMessagesDict method

void setMessagesDict({
  1. required Map<String, String> dict,
  2. String? lang,
})

Sets the message dictionary for a certain language.

Note: This will overwrite the existing map.

If null is passed as dict, an empty Map will be set instead.

Implementation

void setMessagesDict({required Map<String, String> dict, String? lang}) {
  lang ??= currentLanguage;
  _messages[lang] = dict;
}