From a1fbe0b115fd9f9b654dae79f266581c32ba00d2 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Wed, 20 Jan 2016 23:51:37 +0100 Subject: backup db, handle being offline better --- StoneIsland/platforms/ios/www/js/lib/account/ProfileView.js | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'StoneIsland/platforms/ios/www/js/lib/account/ProfileView.js') diff --git a/StoneIsland/platforms/ios/www/js/lib/account/ProfileView.js b/StoneIsland/platforms/ios/www/js/lib/account/ProfileView.js index d36f7f38..df6bc865 100755 --- a/StoneIsland/platforms/ios/www/js/lib/account/ProfileView.js +++ b/StoneIsland/platforms/ios/www/js/lib/account/ProfileView.js @@ -15,6 +15,11 @@ var ProfileView = FormView.extend({ show: function(){ if (! auth.logged_in()) { return app.router.go("intro") } + if (! navigator.onLine) { + app.closed.showElement() + app.closed.setMessage("PLEASE GO ONLINE TO
EDIT YOUR PROFILE.", "") + return + } app.footer.show("SAVE") document.body.className = "profile" if (auth.user.BirthDay.match(/T/)) { -- cgit v1.2.3-70-g09d2