emailuis/nmailui/src/nmattachmentpicker.cpp
changeset 23 2dc6caa42ec3
parent 20 ecc8def7944a
child 30 759dc5235cdb
--- a/emailuis/nmailui/src/nmattachmentpicker.cpp	Mon May 03 12:23:15 2010 +0300
+++ b/emailuis/nmailui/src/nmattachmentpicker.cpp	Fri May 14 15:41:10 2010 +0300
@@ -78,11 +78,10 @@
 void NmAttachmentPicker::fetch(const QString& interface, 
     const QString& operation)
 {
-    if (mRequest) {
-        delete mRequest;
-        mRequest = NULL;
-    }	
-    mRequest = mAppmgr.create(interface, operation, true);
+    delete mRequest;
+    mRequest = NULL;
+    XQApplicationManager appMgr;
+    mRequest = appMgr.create(interface, operation, true);
 
     if (mRequest) {
         mRequest->setSynchronous(false);
@@ -92,13 +91,6 @@
         connect(mRequest, SIGNAL(requestError(int, const QString&)),
                 this, SIGNAL(attachmentsFetchError(int, const QString&)));
         
-        if (!(mRequest)->send()) {
-            //sending request failed
-            NMLOG("appmgr: send request failed");
-        }
-    }
-    else {
-        //create request failed
-        NMLOG("appmgr: create request failed");
-    }      	  
+        mRequest->send();
+    } 
 }