Translations::merge_with
Merges other translations into the current one.
Method of the class: Translations{}
No Hooks.
Returns
null. Nothing (null).
Usage
$Translations = new Translations(); $Translations->merge_with( $other );
- $other(Translations) (required) (passed by reference — &)
- Another Translation object, whose translations will be merged in this one (passed by reference).
Changelog
| Since 2.8.0 | Introduced. |
Translations::merge_with() Translations::merge with code WP 7.0.2
public function merge_with( &$other ) {
foreach ( $other->entries as $entry ) {
$this->entries[ $entry->key() ] = $entry;
}
}