         }
     }
 
-    private func shareProfile() {
-
-         if let username = profileUser?.username, profileURL = NSURL(string: "https://\(yepHost)/\(username)"), nickname = profileUser?.nickname {
-
-            var thumbnail: UIImage?
-
-            if let
-                avatarURLString = profileUser?.avatarURLString,
-                realm = try? Realm(),
-                avatar = avatarWithAvatarURLString(avatarURLString, inRealm: realm) {
-                    if let
-                        avatarFileURL = NSFileManager.yepAvatarURLWithName(avatar.avatarFileName),
-                        avatarFilePath = avatarFileURL.path,
-                        image = UIImage(contentsOfFile: avatarFilePath) {
-                            thumbnail = image.navi_centerCropWithSize(CGSize(width: 100, height: 100))
-                    }
-            }
-
-            let info = MonkeyKing.Info(
-                title: nickname,
-                description: NSLocalizedString("From Yep, with Skills.", comment: ""),
-                thumbnail: thumbnail,
-                media: .URL(profileURL)
-            )
-
-            let sessionMessage = MonkeyKing.Message.WeChat(.Session(info: info))
-
-            let weChatSessionActivity = WeChatActivity(
-                type: .Session,
-                message: sessionMessage,
-                finish: { success in
-                    println("share Profile to WeChat Session success: \(success)")
-                }
-            )
-
-            let timelineMessage = MonkeyKing.Message.WeChat(.Timeline(info: info))
-
-            let weChatTimelineActivity = WeChatActivity(
-                type: .Timeline,
-                message: timelineMessage,
-                finish: { success in
-                    println("share Profile to WeChat Timeline success: \(success)")
-                }
-            )
-            
-            let activityViewController = UIActivityViewController(activityItems: ["\(nickname), \(NSLocalizedString("From Yep, with Skills.", comment: "")) \(profileURL)"], applicationActivities: [weChatSessionActivity, weChatTimelineActivity])
-            activityViewController.excludedActivityTypes = [UIActivityTypeMessage, UIActivityTypeMail]
-            self.presentViewController(activityViewController, animated: true, completion: nil)
-        }
+    private func tryShareProfile() {
+
+        guard let username = profileUser?.username, profileURL = NSURL(string: "https://\(yepHost)/\(username)"), nickname = profileUser?.nickname else {
+            return
+        }
+
+        var thumbnail: UIImage?
+
+        if let
+            avatarURLString = profileUser?.avatarURLString,
+            realm = try? Realm(),
+            avatar = avatarWithAvatarURLString(avatarURLString, inRealm: realm) {
+                if let
+                    avatarFileURL = NSFileManager.yepAvatarURLWithName(avatar.avatarFileName),
+                    avatarFilePath = avatarFileURL.path,
+                    image = UIImage(contentsOfFile: avatarFilePath) {
+                        thumbnail = image.navi_centerCropWithSize(CGSize(width: 100, height: 100))
+                }
+        }
+
+        let info = MonkeyKing.Info(
+            title: nickname,
+            description: NSLocalizedString("From Yep, with Skills.", comment: ""),
+            thumbnail: thumbnail,
+            media: .URL(profileURL)
+        )
+
+        let sessionMessage = MonkeyKing.Message.WeChat(.Session(info: info))
+
+        let weChatSessionActivity = WeChatActivity(
+            type: .Session,
+            message: sessionMessage,
+            finish: { success in
+                println("share Profile to WeChat Session success: \(success)")
+            }
+        )
+
+        let timelineMessage = MonkeyKing.Message.WeChat(.Timeline(info: info))
+
+        let weChatTimelineActivity = WeChatActivity(
+            type: .Timeline,
+            message: timelineMessage,
+            finish: { success in
+                println("share Profile to WeChat Timeline success: \(success)")
+            }
+        )
+        
+        let activityViewController = UIActivityViewController(activityItems: ["\(nickname), \(NSLocalizedString("From Yep, with Skills.", comment: "")) \(profileURL)"], applicationActivities: [weChatSessionActivity, weChatTimelineActivity])
+        activityViewController.excludedActivityTypes = [UIActivityTypeMessage, UIActivityTypeMail]
+
+        self.presentViewController(activityViewController, animated: true, completion: nil)
     }
 
     @objc private func tryShareMyProfile(sender: AnyObject?) {
 
         if let _ = profileUser?.username {
-            shareProfile()
+            tryShareProfile()
 
         } else {
             YepAlert.textInput(title: NSLocalizedString("Create a username", comment: ""), message: NSLocalizedString("In order to share your profile, create a unique username first.", comment: ""), placeholder: NSLocalizedString("use letters, numbers, and underscore", comment: ""), oldText: nil, confirmTitle: NSLocalizedString("Create", comment: ""), cancelTitle: NSLocalizedString("Cancel", comment: ""), inViewController: self, withConfirmAction: { text in

                                }
                        }

                        self?.shareProfile()
                    }
                })


    }

    @objc private func shareOthersProfile(sender: AnyObject) {

        tryShareProfile()
    }

    private func pickSkills() {
