BaconographyPortable.ViewModel.ComposePostViewModel.SubmitImpl C# (CSharp) Method

SubmitImpl() private method

private SubmitImpl ( ) : void
return void
        private async void SubmitImpl()
        {
            if (Url == null)
                Url = "";
            if (Text == null)
                Text = "";

            try
            {
                MessengerInstance.Send<LoadingMessage>(new LoadingMessage { Loading = true });

                if (!Editing)
                {
                    await _redditService.AddPost(Kind, Url, Text, Subreddit, Title);
                }
                else
                {
                    await _redditService.EditPost(Text, _name);
                }

                Url = "";
                Text = "";
                Subreddit = "";
                Title = "";

                _navigationService.GoBack();
            }
            catch (Exception ex)
            {
                _notificationService.CreateNotification("something bad happened while trying to submit your post: " + ex.ToString());
            }
            finally
            {
                MessengerInstance.Send<LoadingMessage>(new LoadingMessage { Loading = false });
            }
            
        }