Translations::merge_originals_with
Merges originals with existing entries.
Method of the class: Translations{}
No Hooks.
Returns
null. Nothing (null).
Usage
$Translations = new Translations(); $Translations->merge_originals_with( $other );
- $other(Translations) (required) (passed by reference — &)
- .
Changelog
| Since 2.8.0 | Introduced. |
Translations::merge_originals_with() Translations::merge originals with code WP 7.0
public function merge_originals_with( &$other ) {
foreach ( $other->entries as $entry ) {
if ( ! isset( $this->entries[ $entry->key() ] ) ) {
$this->entries[ $entry->key() ] = $entry;
} else {
$this->entries[ $entry->key() ]->merge_with( $entry );
}
}
}