address @dignifiedquire Default suggestion

This commit is contained in:
holger krekel
2019-08-20 10:40:27 +02:00
parent f47e637519
commit 287ccb15ba
2 changed files with 4 additions and 4 deletions

View File

@@ -125,7 +125,7 @@ pub const DC_CREATE_MVBOX: usize = 1;
#[repr(i32)]
#[derive(Debug, Display, Clone, Copy, PartialEq, Eq, FromPrimitive, ToPrimitive, ToSql, FromSql)]
pub enum Delay {
DoNotTryAgain = 0,
Default = 0,
AtOnce = -1,
Standard = 3,
IncreationPoll = 2,

View File

@@ -754,7 +754,7 @@ fn job_perform(context: &Context, thread: Thread, probe_network: bool) {
added_timestamp: row.get(4)?,
tries: row.get(6)?,
param: row.get::<_, String>(3)?.parse().unwrap_or_default(),
try_again: Delay::DoNotTryAgain,
try_again: Delay::Default,
pending_error: None,
};
@@ -806,8 +806,8 @@ fn job_perform(context: &Context, thread: Thread, probe_network: bool) {
let mut tries = 0;
while tries <= 1 {
// this can be modified by a job using dc_job_try_again_later()
job.try_again = Delay::DoNotTryAgain;
// this can be modified by a job using try_again_later()
job.try_again = Delay::Default;
match job.action {
Action::SendMsgToSmtp => job.do_DC_JOB_SEND(context),