Skip to content

Commit af77c26

Browse files
committed
Bump to Polylang 3.3.1.
1 parent 36b2ee4 commit af77c26

File tree

1 file changed

+18
-7
lines changed

1 file changed

+18
-7
lines changed

polylang-stubs.php

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4543,17 +4543,23 @@ public function allowed_mimes($mimes)
45434543
class PLL_PO_Export extends \PLL_Export_File
45444544
{
45454545
/**
4546-
* The registered target languages
4546+
* The registered target language.
45474547
*
45484548
* @var string
45494549
*/
4550-
protected $target_language;
4550+
protected $target_language = '';
45514551
/**
4552-
* The registered source_language
4552+
* The registered source language.
45534553
*
45544554
* @var string
45554555
*/
4556-
protected $source_language;
4556+
protected $source_language = '';
4557+
/**
4558+
* The registered site reference.
4559+
*
4560+
* @var string
4561+
*/
4562+
protected $site_reference = '';
45574563
/**
45584564
* PLL_Export_Interface constructor.
45594565
* Creates a PO object.
@@ -4572,7 +4578,6 @@ public function get_source_language()
45724578
{
45734579
}
45744580
/**
4575-
*
45764581
* Set a source language to the export
45774582
*
45784583
* @since 2.7
@@ -4606,7 +4611,6 @@ public function set_target_language($target_language)
46064611
* Set the site reference to the export.
46074612
*
46084613
* @since 2.7
4609-
* @since 3.3 Also adds a reference to the application that generated the export file (name + version).
46104614
*
46114615
* @param string $url Absolute url of the current site.
46124616
* @return void
@@ -4632,6 +4636,7 @@ public function add_translation_entry($type, $source, $target = '', $args = arra
46324636
* Assign a reference to the PO file.
46334637
*
46344638
* @since 2.7
4639+
* @since 3.3.1 Remove unused source reference header.
46354640
*
46364641
* @param string $type Type of data to be exported.
46374642
* @param string $id Optional, unique identifier to retrieve the data in the database.
@@ -4656,7 +4661,10 @@ public function export()
46564661
* @see https://www.gnu.org/software/trans-coord/manual/gnun/html_node/PO-Header.html
46574662
*
46584663
* @since 2.7
4659-
*
4664+
* @since 3.3 Add a reference to the application that generated the export file (name + version).
4665+
* @since 3.3.1 Replace non-official "Language-Target" header to the official Language.
4666+
* Use the Poedit header "X-Source-Language" instead of non official "Language-source".
4667+
* Replace non official 'Site-Reference" header by "X-Polylang-Site-Reference".
46604668
* @return void
46614669
*/
46624670
protected function set_file_headers()
@@ -4770,6 +4778,8 @@ public function import_from_file($filepath)
47704778
* Get the target language
47714779
*
47724780
* @since 2.7
4781+
* @since 3.3.1 Change the target language header label. We're now using the official "Language" header
4782+
* and add a backward condition to accept the old header.
47734783
*
47744784
* @return string|false
47754785
*/
@@ -4780,6 +4790,7 @@ public function get_target_language()
47804790
* Get the site reference.
47814791
*
47824792
* @since 2.7
4793+
* @since 3.3.1 Change the site reference header label.
47834794
*
47844795
* @return string|false
47854796
*/

0 commit comments

Comments
 (0)