function mo_import($lang) { $mo = new MO(); if ($strings = get_option('polylang_mo' . $lang->term_id)) { foreach ($strings as $msg) { $mo->add_entry($mo->make_entry($msg[0], $msg[1])); } } return $mo; }