mirror of
https://github.com/discourse/discourse.git
synced 2024-11-24 02:20:41 +08:00
FIX: don't pop up "cancel" when returning to topic
This commit is contained in:
parent
a75b9db4a2
commit
9e4942eeeb
|
@ -336,15 +336,13 @@ export default DiscourseController.extend({
|
|||
|
||||
// If we're already open, we don't have to do anything
|
||||
if (composerModel.get('composeState') === Discourse.Composer.OPEN &&
|
||||
composerModel.get('draftKey') === opts.draftKey &&
|
||||
composerModel.action === opts.action) {
|
||||
composerModel.get('draftKey') === opts.draftKey) {
|
||||
return resolve();
|
||||
}
|
||||
|
||||
// If it's the same draft, just open it up again.
|
||||
if (composerModel.get('composeState') === Discourse.Composer.DRAFT &&
|
||||
composerModel.get('draftKey') === opts.draftKey &&
|
||||
composerModel.action === opts.action) {
|
||||
composerModel.get('draftKey') === opts.draftKey) {
|
||||
|
||||
composerModel.set('composeState', Discourse.Composer.OPEN);
|
||||
return resolve();
|
||||
|
|
Loading…
Reference in New Issue
Block a user