Fixed a routing error when a "sent" post was edited

refs https://github.com/TryGhost/Team/issues/954

- When an email-only post with a "sent" status was edited, it's status changed to "draft", which is an incorrect behavior. This change is causing the "sent" status to persist and removes the transition error.
This commit is contained in:
Naz 2021-08-31 20:06:36 +04:00
parent c27194efc5
commit f2883c3636

View File

@ -470,6 +470,8 @@ export default Controller.extend({
status = 'published';
} else if (this.willSchedule && !this.get('post.isPublished')) {
status = 'scheduled';
} else if (this.get('post.isSent')) {
status = 'sent';
} else {
status = 'draft';
}