{"action":"created","issue":{"url":"https://api.github.com/repos/driftyco/ionic-plugin-deploy/issues/67","repository_url":"https://api.github.com/repos/driftyco/ionic-plugin-deploy","labels_url":"https://api.github.com/repos/driftyco/ionic-plugin-deploy/issues/67/labels{/name}","comments_url":"https://api.github.com/repos/driftyco/ionic-plugin-deploy/issues/67/comments","events_url":"https://api.github.com/repos/driftyco/ionic-plugin-deploy/issues/67/events","html_url":"https://github.com/driftyco/ionic-plugin-deploy/issues/67","id":154304423,"number":67,"title":"reopen app for second time after rollback gets wrong version ","user":{"login":"MarwaAbuEssa","id":7272394,"avatar_url":"https://avatars.githubusercontent.com/u/7272394?v=3","gravatar_id":"","url":"https://api.github.com/users/MarwaAbuEssa","html_url":"https://github.com/MarwaAbuEssa","followers_url":"https://api.github.com/users/MarwaAbuEssa/followers","following_url":"https://api.github.com/users/MarwaAbuEssa/following{/other_user}","gists_url":"https://api.github.com/users/MarwaAbuEssa/gists{/gist_id}","starred_url":"https://api.github.com/users/MarwaAbuEssa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MarwaAbuEssa/subscriptions","organizations_url":"https://api.github.com/users/MarwaAbuEssa/orgs","repos_url":"https://api.github.com/users/MarwaAbuEssa/repos","events_url":"https://api.github.com/users/MarwaAbuEssa/events{/privacy}","received_events_url":"https://api.github.com/users/MarwaAbuEssa/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-05-11T17:57:03Z","updated_at":"2016-05-11T22:59:07Z","closed_at":null,"body":"hi,\r\n\r\nI'm using la tested Ionic-deploy plugin Version , using the following code :\r\n\r\n deploy.setChannel(\"dev\");\r\n            deploy.check().then(function(response) {\r\n            // response will be true/false\r\n            if (response) {\r\n                // Download the updates\r\n                deploy.download().then(function() {\r\n                // Extract the updates\r\n                deploy.extract().then(function() {\r\n                    // Load the updated version\r\n                 \r\n                    deploy.load();\r\n                    $ionicLoading.hide();\r\n                }, function(error) {\r\n                    // Error extracting\r\n                }, function(progress) {\r\n                    // Do something with the zip extraction progress\r\n                       $ionicLoading.hide();\r\n                       $rootScope.extractprogress = progress\r\n                     $ionicLoading.show(\r\n                           {\r\n                               template: '<i class=\" ion-loading-c\"></i> ' + \"One moment please...Exatracting <br>{{extractprogress}}%\",\r\n                               animation: 'fade-in',\r\n                               showBackdrop: true,\r\n                               maxWidth: 200,\r\n                               showDelay: 0,\r\n            \r\n                           })\r\n                           \r\n                   //  deploy.load();\r\n                    console.log(progress);\r\n                });\r\n                }, function(error) {\r\n                // Error downloading the updates\r\n                }, function(progress) {\r\n                      $rootScope.progress = progress\r\n                     $ionicLoading.show(\r\n                           {\r\n                               template: '<i class=\" ion-loading-c\"></i> ' + \"A minor update is being applied to iRehearse. Downloading...<br>{{progress}}%\",\r\n                               animation: 'fade-in',\r\n                               showBackdrop: true,\r\n                               maxWidth: 200,\r\n                               showDelay: 0,\r\n            \r\n                           })\r\n                // Do something with the download progress\r\n                console.log(progress);\r\n                });\r\n            }\r\n            }, function(error) {\r\n            // Error checking for updates\r\n            });\r\n\r\nnow I had a build version 1.2.1 at android emulator , and do the following \r\n1- make update => upload it => set equivalent version to 1.2.2 => deploy => and done successfully\r\n2- make update => upload it => set equivalent version to 1.2.3 => deploy => and done successfully\r\nso now i had Version 1.2.3 running at my emulator \r\nnow rollback to version 1.2.2 => open the app => found version 1.2.2\r\nthe problem is after closing and reopening the app again => found version 1.2.1 :-1: \r\n\r\n- i checked the active version at the deployment channel => still found 1.2.2\r\n\r\nso the problem is reopening the app for the second time after rolling back gets the last build version not the rolled back version  "},"comment":{"url":"https://api.github.com/repos/driftyco/ionic-plugin-deploy/issues/comments/218614904","html_url":"https://github.com/driftyco/ionic-plugin-deploy/issues/67#issuecomment-218614904","issue_url":"https://api.github.com/repos/driftyco/ionic-plugin-deploy/issues/67","id":218614904,"user":{"login":"Mohamed-Habshey","id":13639510,"avatar_url":"https://avatars.githubusercontent.com/u/13639510?v=3","gravatar_id":"","url":"https://api.github.com/users/Mohamed-Habshey","html_url":"https://github.com/Mohamed-Habshey","followers_url":"https://api.github.com/users/Mohamed-Habshey/followers","following_url":"https://api.github.com/users/Mohamed-Habshey/following{/other_user}","gists_url":"https://api.github.com/users/Mohamed-Habshey/gists{/gist_id}","starred_url":"https://api.github.com/users/Mohamed-Habshey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mohamed-Habshey/subscriptions","organizations_url":"https://api.github.com/users/Mohamed-Habshey/orgs","repos_url":"https://api.github.com/users/Mohamed-Habshey/repos","events_url":"https://api.github.com/users/Mohamed-Habshey/events{/privacy}","received_events_url":"https://api.github.com/users/Mohamed-Habshey/received_events","type":"User","site_admin":false},"created_at":"2016-05-11T22:59:07Z","updated_at":"2016-05-11T22:59:07Z","body":":+1:  same here"}}