• Hi,

    It seems that when importing posts, it will break this plugin. It gives this error:

    “polylang array_intersect_key(): Argument #1 is not an array”

    Chancing line 180 of file “translated-object.php” to this:

    if(isset($translations) && is_array($translations)) {
    $translations = array_intersect_key( $translations, array_flip( $this->model->get_languages_list( array( 'fields' => 'slug' ) ) ) );
    }

    Fixes the problem. I wish you could include this fix in to the next release, please.

    Thank you!

    https://www.ads-software.com/plugins/polylang/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Chouby

    (@chouby)

    Hi!

    Thanks for the report. May I know how you import posts?

    Thread Starter webbisivut.org

    (@w-labs)

    Im using WordPress’ own import tool. Tools -> Import. I first translated posts and then I needed to move my website to another server, so I used WordPress export/import tool to move posts, but those posts got broken after import.

    Plugin Author Chouby

    (@chouby)

    I will fix the code. But I was not able to reproduce the issue with WordPress importer, which doesn’t allow me to see if there is not something else hidden behind it ??

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Importing posts breaks this plugin’ is closed to new replies.