diff --git a/src/client/application/application-controller.vala b/src/client/application/application-controller.vala index 04e04909..a6cdaf2f 100644 --- a/src/client/application/application-controller.vala +++ b/src/client/application/application-controller.vala @@ -1792,7 +1792,7 @@ internal class Application.Controller : Geary.BaseObject { debug("Checking for backgrounded idle work"); foreach (AccountContext context in this.accounts.values) { Geary.Account account = context.account; - account.app_backgrounded_cleanup.begin(context.cancellable); + account.cleanup_storage.begin(context.cancellable); } } diff --git a/src/engine/api/geary-account.vala b/src/engine/api/geary-account.vala index 5e2641b4..7ed28141 100644 --- a/src/engine/api/geary-account.vala +++ b/src/engine/api/geary-account.vala @@ -520,12 +520,14 @@ public abstract class Geary.Account : BaseObject, Logging.Source { } /** - * Run account cleanup work if the appropriate interval has past since - * last execution. Alternatively if the interval has not past but vacuum - * GC has been flagged to run this will be executed. Designed to be run + * Perform cleanup of account storage. + * + * Work is performed if the appropriate interval has past since last + * execution. Alternatively if the interval has not past but vacuum GC + * has been flagged to run this will be executed. Designed to be run * while the app is in the background and idle. */ - public abstract async void app_backgrounded_cleanup(Cancellable? cancellable); + public abstract async void cleanup_storage(Cancellable? cancellable); /** Fires a {@link opened} signal. */ protected virtual void notify_opened() { diff --git a/src/engine/imap-engine/imap-engine-generic-account.vala b/src/engine/imap-engine/imap-engine-generic-account.vala index a6b4f2d5..da5bec38 100644 --- a/src/engine/imap-engine/imap-engine-generic-account.vala +++ b/src/engine/imap-engine/imap-engine-generic-account.vala @@ -531,8 +531,8 @@ private abstract class Geary.ImapEngine.GenericAccount : Geary.Account { } /** {@inheritDoc} */ - public override async void app_backgrounded_cleanup(Cancellable? cancellable) { - debug("Backgrounded cleanup check for %s account", this.information.display_name); + public override async void cleanup_storage(Cancellable? cancellable) { + debug("Backgrounded storage cleanup check for %s account", this.information.display_name); DateTime now = new DateTime.now_local(); DateTime? last_cleanup = this.last_storage_cleanup; diff --git a/test/engine/api/geary-account-mock.vala b/test/engine/api/geary-account-mock.vala index 77ca8287..f7b63f4c 100644 --- a/test/engine/api/geary-account-mock.vala +++ b/test/engine/api/geary-account-mock.vala @@ -274,7 +274,7 @@ public class Geary.MockAccount : Account, MockObject { ); } - public override async void app_backgrounded_cleanup(Cancellable? cancellable) { + public override async void cleanup_storage(Cancellable? cancellable) { } }