mirror of
https://github.com/M66B/FairEmail.git
synced 2026-01-04 03:43:55 +01:00
Add signed-only drafts to remote server
This commit is contained in:
@@ -121,6 +121,14 @@ public class EntityOperation {
|
|||||||
for (Object value : values)
|
for (Object value : values)
|
||||||
jargs.put(value);
|
jargs.put(value);
|
||||||
|
|
||||||
|
if (ADD.equals(name) &&
|
||||||
|
(EntityMessage.PGP_SIGNENCRYPT.equals(message.encrypt) ||
|
||||||
|
EntityMessage.SMIME_SIGNENCRYPT.equals(message.encrypt))) {
|
||||||
|
EntityFolder folder = db.folder().getFolder(message.folder);
|
||||||
|
if (folder != null && EntityFolder.DRAFTS.equals(folder.type))
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (MOVE.equals(name) &&
|
if (MOVE.equals(name) &&
|
||||||
(EntityMessage.PGP_SIGNENCRYPT.equals(message.encrypt) ||
|
(EntityMessage.PGP_SIGNENCRYPT.equals(message.encrypt) ||
|
||||||
EntityMessage.SMIME_SIGNENCRYPT.equals(message.encrypt))) {
|
EntityMessage.SMIME_SIGNENCRYPT.equals(message.encrypt))) {
|
||||||
|
|||||||
@@ -2985,8 +2985,7 @@ public class FragmentCompose extends FragmentBase {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (data.draft.encrypt == null || data.draft.encrypt == 0)
|
EntityOperation.queue(context, data.draft, EntityOperation.ADD);
|
||||||
EntityOperation.queue(context, data.draft, EntityOperation.ADD);
|
|
||||||
} else {
|
} else {
|
||||||
if (data.draft.revision == null) {
|
if (data.draft.revision == null) {
|
||||||
data.draft.revision = 1;
|
data.draft.revision = 1;
|
||||||
@@ -3291,7 +3290,7 @@ public class FragmentCompose extends FragmentBase {
|
|||||||
draft.ui_hide = ui_hide;
|
draft.ui_hide = ui_hide;
|
||||||
db.message().updateMessage(draft);
|
db.message().updateMessage(draft);
|
||||||
|
|
||||||
if (draft.content && (draft.encrypt == null || draft.encrypt == 0))
|
if (draft.content)
|
||||||
EntityOperation.queue(context, draft, EntityOperation.ADD);
|
EntityOperation.queue(context, draft, EntityOperation.ADD);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3467,8 +3466,7 @@ public class FragmentCompose extends FragmentBase {
|
|||||||
action == R.id.action_redo ||
|
action == R.id.action_redo ||
|
||||||
action == R.id.action_check) {
|
action == R.id.action_check) {
|
||||||
if (BuildConfig.DEBUG || dirty)
|
if (BuildConfig.DEBUG || dirty)
|
||||||
if (draft.encrypt == null || draft.encrypt == 0)
|
EntityOperation.queue(context, draft, EntityOperation.ADD);
|
||||||
EntityOperation.queue(context, draft, EntityOperation.ADD);
|
|
||||||
|
|
||||||
if (action == R.id.action_check) {
|
if (action == R.id.action_check) {
|
||||||
// Check data
|
// Check data
|
||||||
|
|||||||
Reference in New Issue
Block a user