Skip to content

Unable to move posts for deleted users #20

Description

@garygreen

When the poster has deleted their account, an error is generated in http request and the button continues to spin:

image

It's related to this line:

MovePostsHandler.php

/**
 * Creates a target discussion when specified.
 */
protected function createTargetDiscussion(Discussion $sourceDiscussion, CommentPost $firstPost, string $title, bool $emulate): Discussion
{
    $discussion = Discussion::start($title, $firstPost->user);

When starting the discussion it appears an actual User is required, but the user of the post deleted their account. Maybe it needs to support Guest user of some kind here?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions