Skip to content

Rewrite assets urls when restoring Playground from a zip file #2982

@adamziel

Description

@adamziel

Exporting playground and restoring the zip file leaves image urls broken - they point to the previous site scope instead of the new one.

Let's rewrite those scope references during the .zip import process.

One easy way of doing that would be including the scope in the zipped export and running an SQLite update query to replace the scope:name substring - which is reasonably unique and unlike to be encoded as something different than ascii.

A more reliable way would be repurposing the WCR URL rewriting pipeline, but that will require more effort and we'll get there anyway as a side-product of the WordPress importer plugin work so we might as well do the UPDATE query for bow and migrate to this pipeline eventually.

Metadata

Metadata

Assignees

No one assigned

    Labels

    [Type] BugAn existing feature does not function as intended

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions