parent_store = camel_folder_get_parent_store (folder);
istore = CAMEL_IMAPX_STORE (parent_store);
- if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL)
- return TRUE;
+ if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL) {
+ g_set_error (
+ error, CAMEL_SERVICE_ERROR,
+ CAMEL_SERVICE_ERROR_UNAVAILABLE,
+ _("You must be working online to complete this operation"));
+ return FALSE;
+ }
if (!camel_service_connect((CamelService *)istore, error))
return FALSE;
parent_store = camel_folder_get_parent_store (folder);
istore = CAMEL_IMAPX_STORE (parent_store);
- if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL)
- return TRUE;
+ if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL) {
+ g_set_error (
+ error, CAMEL_SERVICE_ERROR,
+ CAMEL_SERVICE_ERROR_UNAVAILABLE,
+ _("You must be working online to complete this operation"));
+ return FALSE;
+ }
server = camel_imapx_store_get_server(istore, camel_folder_get_full_name (folder), error);
if (server) {
parent_store = camel_folder_get_parent_store (folder);
istore = CAMEL_IMAPX_STORE (parent_store);
- if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL)
- return TRUE;
+ if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL) {
+ g_set_error (
+ error, CAMEL_SERVICE_ERROR,
+ CAMEL_SERVICE_ERROR_UNAVAILABLE,
+ _("You must be working online to complete this operation"));
+ return FALSE;
+ }
server = camel_imapx_store_get_server(istore, camel_folder_get_full_name (folder), NULL);
if (server)
return NULL;
}
- if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL)
+ if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL) {
+ g_set_error (
+ error, CAMEL_SERVICE_ERROR,
+ CAMEL_SERVICE_ERROR_UNAVAILABLE,
+ _("You must be working online to complete this operation"));
return NULL;
+ }
server = camel_imapx_store_get_server(istore, camel_folder_get_full_name (folder), error);
if (server) {
parent_store = camel_folder_get_parent_store (folder);
istore = CAMEL_IMAPX_STORE (parent_store);
- if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL)
- return TRUE;
+ if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL) {
+ g_set_error (
+ error, CAMEL_SERVICE_ERROR,
+ CAMEL_SERVICE_ERROR_UNAVAILABLE,
+ _("You must be working online to complete this operation"));
+ return FALSE;
+ }
server = camel_imapx_store_get_server (istore, camel_folder_get_full_name (folder), error);
if (server == NULL)
parent_store = camel_folder_get_parent_store (source);
istore = CAMEL_IMAPX_STORE (parent_store);
- if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL)
- return TRUE;
+ if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL) {
+ g_set_error (
+ error, CAMEL_SERVICE_ERROR,
+ CAMEL_SERVICE_ERROR_UNAVAILABLE,
+ _("You must be working online to complete this operation"));
+ return FALSE;
+ }
server = camel_imapx_store_get_server (istore, camel_folder_get_full_name (source), error);
if (server) {
parent_store = camel_folder_get_parent_store (folder);
istore = CAMEL_IMAPX_STORE (parent_store);
- if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL)
- return TRUE;
+ if (CAMEL_OFFLINE_STORE (istore)->state == CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL) {
+ g_set_error (
+ error, CAMEL_SERVICE_ERROR,
+ CAMEL_SERVICE_ERROR_UNAVAILABLE,
+ _("You must be working online to complete this operation"));
+ return FALSE;
+ }
if (appended_uid)
*appended_uid = NULL;