Update check
This commit is contained in:
parent
8877ea6c6c
commit
ef8ddaf380
@ -96,8 +96,8 @@ $(document).ready(function() {
|
|||||||
latest.onload = function() {
|
latest.onload = function() {
|
||||||
if( this.response ) {
|
if( this.response ) {
|
||||||
var lapp = JSON.parse(this.response);
|
var lapp = JSON.parse(this.response);
|
||||||
console.log(lapp.version);
|
alert(lapp.version);
|
||||||
console.log(app.manifest.version);
|
alert(app.manifest.version);
|
||||||
if( lapp.version != app.manifest.version &&
|
if( lapp.version != app.manifest.version &&
|
||||||
confirm('A new version of this app is available, do you want to update? ' + app.manifest.version + ' to ' + lapp.version )) {
|
confirm('A new version of this app is available, do you want to update? ' + app.manifest.version + ' to ' + lapp.version )) {
|
||||||
var ins = navigator.mozApps.install('http://mdibaiee.github.io/Sketchy/Web/manifest-web.webapp');
|
var ins = navigator.mozApps.install('http://mdibaiee.github.io/Sketchy/Web/manifest-web.webapp');
|
||||||
|
Loading…
Reference in New Issue
Block a user