Skip to content

Commit

Permalink
Fix marking as spam/ham on moving messages with Move menu (#7189)
Browse files Browse the repository at this point in the history
  • Loading branch information
alecpl committed Mar 30, 2020
1 parent e0b56ae commit cb8c078
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions program/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -735,7 +735,7 @@ function rcube_webmail()
/*********************************************************/

// execute a specific command on the web client
this.command = function(command, props, obj, event)
this.command = function(command, props, obj, event, allow_disabled)
{
var ret;

Expand All @@ -753,7 +753,7 @@ function rcube_webmail()
}

// command not supported or allowed
if (!this.commands[command]) {
if (!allow_disabled && !this.commands[command]) {
// pass command to parent window
if (this.is_framed())
parent.rcmail.command(command, props);
Expand Down Expand Up @@ -3198,12 +3198,13 @@ function rcube_webmail()
this.copy_messages = function(mbox, event, uids)
{
if (mbox && typeof mbox === 'object') {
if (mbox.uids) uids = mbox.uids;
mbox = mbox.id;
}
else if (!mbox) {
uids = this.env.uid ? [this.env.uid] : this.message_list.get_selection();
return this.folder_selector(event, function(folder) {
ref.copy_messages(folder, null, uids);
return this.folder_selector(event, function(folder, obj) {
ref.command('copy', {id: folder, uids: uids}, obj, event, true);
});
}

Expand All @@ -3225,12 +3226,13 @@ function rcube_webmail()
this.move_messages = function(mbox, event, uids)
{
if (mbox && typeof mbox === 'object') {
if (mbox.uids) uids = mbox.uids;
mbox = mbox.id;
}
else if (!mbox) {
uids = this.env.uid ? [this.env.uid] : this.message_list.get_selection();
return this.folder_selector(event, function(folder) {
ref.move_messages(folder, null, uids);
return this.folder_selector(event, function(folder, obj) {
ref.command('move', {id: folder, uids: uids}, obj, event, true);
});
}

Expand Down

0 comments on commit cb8c078

Please sign in to comment.