+ /* The above function could return NULL */
+ if (!priv->account) {
+ /* Check if the operation was a success */
+ g_set_error (&(priv->error), MODEST_MAIL_OPERATION_ERROR,
+ MODEST_MAIL_OPERATION_ERROR_ITEM_NOT_FOUND,
+ "no account");
+ priv->status = MODEST_MAIL_OPERATION_STATUS_FAILED;
+
+ /* Call the user callback */
+ if (callback)
+ callback (self, NULL, user_data);
+
+ /* Notify about operation end */
+ modest_mail_operation_notify_end (self);
+
+ return;
+ }
+