{"action":"created","comment":{"url":"https://api.github.com/repos/andela/suyabay/pulls/comments/62361730","id":62361730,"diff_hunk":"@@ -48,33 +47,33 @@ function processAjaxApiCall(url, parameter)\n  */\n function confirmApiDelete(url)\n {\n-    swal({   \n-        title: \"Are you sure?\",   \n-        text: \"You will not be able to recover this app!\",   \n-        type: \"warning\",   \n-        showCancelButton: true,   \n-        confirmButtonColor: \"#26a69a\",   \n-        confirmButtonText: \"Yes, delete it!\",   \n-        cancelButtonText: \"No, retain my app!\",   \n-        closeOnConfirm: false,   \n-        closeOnCancel: false \n-    }, \n+    swal({\n+        title: \"Are you sure?\",\n+        text: \"You will not be able to recover this app!\",\n+        type: \"warning\",\n+        showCancelButton: true,\n+        confirmButtonColor: \"#26a69a\",\n+        confirmButtonText: \"Yes, delete it!\",\n+        cancelButtonText: \"No, retain my app!\",\n+        closeOnConfirm: false,\n+        closeOnCancel: false\n+    },\n \n     function(isConfirm)\n-    {   \n+    {\n         if (isConfirm) {\n-    \t    processAjaxApiCall(url);\n+    \t    processDeleteAjaxCall(url);\n         } else {\n-    \t    swal(\"Cancelled\", \"Your app will be retained\", \"error\");   \n-        } \n+    \t    swal(\"Cancelled\", \"Your app will be retained\", \"error\");","path":"public/js/api.js","position":59,"original_position":59,"commit_id":"75dbc217e461ab95e14408acffaefe7fa39ac5df","original_commit_id":"75dbc217e461ab95e14408acffaefe7fa39ac5df","user":{"login":"houndci-bot","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"'swal' is not defined.","created_at":"2016-05-06T17:28:42Z","updated_at":"2016-05-06T17:28:42Z","html_url":"https://github.com/andela/suyabay/pull/272#discussion_r62361730","pull_request_url":"https://api.github.com/repos/andela/suyabay/pulls/272","_links":{"self":{"href":"https://api.github.com/repos/andela/suyabay/pulls/comments/62361730"},"html":{"href":"https://github.com/andela/suyabay/pull/272#discussion_r62361730"},"pull_request":{"href":"https://api.github.com/repos/andela/suyabay/pulls/272"}}},"pull_request":{"url":"https://api.github.com/repos/andela/suyabay/pulls/272","id":68483680,"html_url":"https://github.com/andela/suyabay/pull/272","diff_url":"https://github.com/andela/suyabay/pull/272.diff","patch_url":"https://github.com/andela/suyabay/pull/272.patch","issue_url":"https://api.github.com/repos/andela/suyabay/issues/272","number":272,"state":"open","locked":false,"title":"#117795263 Developers should be able to edit their apps","user":{"login":"andela-araimi","id":14159420,"avatar_url":"https://avatars.githubusercontent.com/u/14159420?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-araimi","html_url":"https://github.com/andela-araimi","followers_url":"https://api.github.com/users/andela-araimi/followers","following_url":"https://api.github.com/users/andela-araimi/following{/other_user}","gists_url":"https://api.github.com/users/andela-araimi/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-araimi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-araimi/subscriptions","organizations_url":"https://api.github.com/users/andela-araimi/orgs","repos_url":"https://api.github.com/users/andela-araimi/repos","events_url":"https://api.github.com/users/andela-araimi/events{/privacy}","received_events_url":"https://api.github.com/users/andela-araimi/received_events","type":"User","site_admin":false},"body":"#### What does this PR do?\r\n\r\nGive developers the privilege to edit their apps.\r\n\r\n#### Description of Task to be completed?\r\n\r\nDevelopers are given the privilege to edit their apps. Javascript is used to implement this task. It is implemented in such a way that if developers change any of the details to what we already have in the database, an error message will pop-up informing the developers that the app already exist in the database. And on the other hands, if the update is not successful, an error message will also pop-up informing the developers about the error. Validation of both the name, description and url is also implemented with the necessary error display to the developer.\r\n\r\n#### How should this be manually tested?\r\n\r\nFrom the `My app` page, which displays all the apps the developers have on suyabay. Each title of the apps is linked to another page which displays the full details of the app. In this page, an  `edit button` is located above the app details. Click on this `edit button`. It navigates to a form which has the developer's details and below it is an `update button`. Click on this `update button` it displays a pop-up. \r\n\r\nThe displayed pop-up depends on whether the update is successful or not. If the app updated successfully, a pop-up that displays `app updated successfully` will be displayed and immediately redirect back to  all apps the developers have, including the updated app. If the app already exists in the database, a pop-up that displays `app already exist` will be displayed. And if the app didn't update successfully, a pop-up that displays `app was unable to update` will be displayed.\r\n\r\n#### Any background context you want to provide?\r\nNone\r\n#### What are the relevant pivotal tracker stories?\r\n#117795263\r\n#### Screenshots (if appropriate)\r\n\r\n\r\n![screen shot 2016-05-01 at 1 50 19 am](https://cloud.githubusercontent.com/assets/14159420/14939447/5426daa6-0f3f-11e6-9962-d85f82a2c0c4.png)\r\n![screen shot 2016-05-01 at 1 50 55 am](https://cloud.githubusercontent.com/assets/14159420/14939448/5cc6e0fc-0f3f-11e6-964f-71429cf3d5e6.png)\r\n\r\n\r\n\r\n#### Questions:\r\n[@unicodeveloper](https://github.com/unicodeveloper)\r\n[@andela-oadebayo](https://github.com/andela-oadebayo)","created_at":"2016-05-01T01:02:37Z","updated_at":"2016-05-06T17:28:42Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e6cced0e11aa5f7b1e3e80b7d5f6f66c76b65a42","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/andela/suyabay/pulls/272/commits","review_comments_url":"https://api.github.com/repos/andela/suyabay/pulls/272/comments","review_comment_url":"https://api.github.com/repos/andela/suyabay/pulls/comments{/number}","comments_url":"https://api.github.com/repos/andela/suyabay/issues/272/comments","statuses_url":"https://api.github.com/repos/andela/suyabay/statuses/75dbc217e461ab95e14408acffaefe7fa39ac5df","head":{"label":"andela:ft-developers-should-be-able-to-edit-their-apps-#117795263","ref":"ft-developers-should-be-able-to-edit-their-apps-#117795263","sha":"75dbc217e461ab95e14408acffaefe7fa39ac5df","user":{"login":"andela","id":4100206,"avatar_url":"https://avatars.githubusercontent.com/u/4100206?v=3","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"repo":{"id":41855319,"name":"suyabay","full_name":"andela/suyabay","owner":{"login":"andela","id":4100206,"avatar_url":"https://avatars.githubusercontent.com/u/4100206?v=3","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/andela/suyabay","description":"Awesome Podcast FM Network for Suya Lovers","fork":false,"url":"https://api.github.com/repos/andela/suyabay","forks_url":"https://api.github.com/repos/andela/suyabay/forks","keys_url":"https://api.github.com/repos/andela/suyabay/keys{/key_id}","collaborators_url":"https://api.github.com/repos/andela/suyabay/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/andela/suyabay/teams","hooks_url":"https://api.github.com/repos/andela/suyabay/hooks","issue_events_url":"https://api.github.com/repos/andela/suyabay/issues/events{/number}","events_url":"https://api.github.com/repos/andela/suyabay/events","assignees_url":"https://api.github.com/repos/andela/suyabay/assignees{/user}","branches_url":"https://api.github.com/repos/andela/suyabay/branches{/branch}","tags_url":"https://api.github.com/repos/andela/suyabay/tags","blobs_url":"https://api.github.com/repos/andela/suyabay/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/andela/suyabay/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/andela/suyabay/git/refs{/sha}","trees_url":"https://api.github.com/repos/andela/suyabay/git/trees{/sha}","statuses_url":"https://api.github.com/repos/andela/suyabay/statuses/{sha}","languages_url":"https://api.github.com/repos/andela/suyabay/languages","stargazers_url":"https://api.github.com/repos/andela/suyabay/stargazers","contributors_url":"https://api.github.com/repos/andela/suyabay/contributors","subscribers_url":"https://api.github.com/repos/andela/suyabay/subscribers","subscription_url":"https://api.github.com/repos/andela/suyabay/subscription","commits_url":"https://api.github.com/repos/andela/suyabay/commits{/sha}","git_commits_url":"https://api.github.com/repos/andela/suyabay/git/commits{/sha}","comments_url":"https://api.github.com/repos/andela/suyabay/comments{/number}","issue_comment_url":"https://api.github.com/repos/andela/suyabay/issues/comments{/number}","contents_url":"https://api.github.com/repos/andela/suyabay/contents/{+path}","compare_url":"https://api.github.com/repos/andela/suyabay/compare/{base}...{head}","merges_url":"https://api.github.com/repos/andela/suyabay/merges","archive_url":"https://api.github.com/repos/andela/suyabay/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/andela/suyabay/downloads","issues_url":"https://api.github.com/repos/andela/suyabay/issues{/number}","pulls_url":"https://api.github.com/repos/andela/suyabay/pulls{/number}","milestones_url":"https://api.github.com/repos/andela/suyabay/milestones{/number}","notifications_url":"https://api.github.com/repos/andela/suyabay/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/andela/suyabay/labels{/name}","releases_url":"https://api.github.com/repos/andela/suyabay/releases{/id}","deployments_url":"https://api.github.com/repos/andela/suyabay/deployments","created_at":"2015-09-03T11:00:56Z","updated_at":"2016-03-11T18:32:31Z","pushed_at":"2016-05-06T17:28:31Z","git_url":"git://github.com/andela/suyabay.git","ssh_url":"git@github.com:andela/suyabay.git","clone_url":"https://github.com/andela/suyabay.git","svn_url":"https://github.com/andela/suyabay","homepage":"https://suyabay-staging.herokuapp.com","size":35817,"stargazers_count":8,"watchers_count":8,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":7,"forks":4,"open_issues":7,"watchers":8,"default_branch":"staging"}},"base":{"label":"andela:staging","ref":"staging","sha":"a94a1c925f01ba85ee73d316fa952c6aa8b2cc17","user":{"login":"andela","id":4100206,"avatar_url":"https://avatars.githubusercontent.com/u/4100206?v=3","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"repo":{"id":41855319,"name":"suyabay","full_name":"andela/suyabay","owner":{"login":"andela","id":4100206,"avatar_url":"https://avatars.githubusercontent.com/u/4100206?v=3","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/andela/suyabay","description":"Awesome Podcast FM Network for Suya Lovers","fork":false,"url":"https://api.github.com/repos/andela/suyabay","forks_url":"https://api.github.com/repos/andela/suyabay/forks","keys_url":"https://api.github.com/repos/andela/suyabay/keys{/key_id}","collaborators_url":"https://api.github.com/repos/andela/suyabay/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/andela/suyabay/teams","hooks_url":"https://api.github.com/repos/andela/suyabay/hooks","issue_events_url":"https://api.github.com/repos/andela/suyabay/issues/events{/number}","events_url":"https://api.github.com/repos/andela/suyabay/events","assignees_url":"https://api.github.com/repos/andela/suyabay/assignees{/user}","branches_url":"https://api.github.com/repos/andela/suyabay/branches{/branch}","tags_url":"https://api.github.com/repos/andela/suyabay/tags","blobs_url":"https://api.github.com/repos/andela/suyabay/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/andela/suyabay/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/andela/suyabay/git/refs{/sha}","trees_url":"https://api.github.com/repos/andela/suyabay/git/trees{/sha}","statuses_url":"https://api.github.com/repos/andela/suyabay/statuses/{sha}","languages_url":"https://api.github.com/repos/andela/suyabay/languages","stargazers_url":"https://api.github.com/repos/andela/suyabay/stargazers","contributors_url":"https://api.github.com/repos/andela/suyabay/contributors","subscribers_url":"https://api.github.com/repos/andela/suyabay/subscribers","subscription_url":"https://api.github.com/repos/andela/suyabay/subscription","commits_url":"https://api.github.com/repos/andela/suyabay/commits{/sha}","git_commits_url":"https://api.github.com/repos/andela/suyabay/git/commits{/sha}","comments_url":"https://api.github.com/repos/andela/suyabay/comments{/number}","issue_comment_url":"https://api.github.com/repos/andela/suyabay/issues/comments{/number}","contents_url":"https://api.github.com/repos/andela/suyabay/contents/{+path}","compare_url":"https://api.github.com/repos/andela/suyabay/compare/{base}...{head}","merges_url":"https://api.github.com/repos/andela/suyabay/merges","archive_url":"https://api.github.com/repos/andela/suyabay/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/andela/suyabay/downloads","issues_url":"https://api.github.com/repos/andela/suyabay/issues{/number}","pulls_url":"https://api.github.com/repos/andela/suyabay/pulls{/number}","milestones_url":"https://api.github.com/repos/andela/suyabay/milestones{/number}","notifications_url":"https://api.github.com/repos/andela/suyabay/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/andela/suyabay/labels{/name}","releases_url":"https://api.github.com/repos/andela/suyabay/releases{/id}","deployments_url":"https://api.github.com/repos/andela/suyabay/deployments","created_at":"2015-09-03T11:00:56Z","updated_at":"2016-03-11T18:32:31Z","pushed_at":"2016-05-06T17:28:31Z","git_url":"git://github.com/andela/suyabay.git","ssh_url":"git@github.com:andela/suyabay.git","clone_url":"https://github.com/andela/suyabay.git","svn_url":"https://github.com/andela/suyabay","homepage":"https://suyabay-staging.herokuapp.com","size":35817,"stargazers_count":8,"watchers_count":8,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":7,"forks":4,"open_issues":7,"watchers":8,"default_branch":"staging"}},"_links":{"self":{"href":"https://api.github.com/repos/andela/suyabay/pulls/272"},"html":{"href":"https://github.com/andela/suyabay/pull/272"},"issue":{"href":"https://api.github.com/repos/andela/suyabay/issues/272"},"comments":{"href":"https://api.github.com/repos/andela/suyabay/issues/272/comments"},"review_comments":{"href":"https://api.github.com/repos/andela/suyabay/pulls/272/comments"},"review_comment":{"href":"https://api.github.com/repos/andela/suyabay/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/andela/suyabay/pulls/272/commits"},"statuses":{"href":"https://api.github.com/repos/andela/suyabay/statuses/75dbc217e461ab95e14408acffaefe7fa39ac5df"}}}}